small patches

This commit is contained in:
tTh
2023-10-06 21:34:11 +02:00
parent 5d139312e2
commit cfe9f8cdae
5 changed files with 56 additions and 50 deletions

View File

@@ -20,13 +20,41 @@
* https://git.tetalab.org/tTh/FloatImg
*/
#define FIMG_VERSION (224)
#define FIMG_VERSION (226)
#define RELEASE_NAME ("noname")
#define PATCH_LEVEL ("aaaa")
/* XXX add a test for stdint.h / uint32_t XXX */
#include <stdint.h>
/*
* new 11 mars 2022, and a lot of iterations
* around the concept of metadata for my work.
*/
/*
* we MUST look at packing and endianess problems NOW
* and we can think about a fixed size of this datablock
*/
#define MAGIC_MDATA 0xfe007007
typedef struct {
uint32_t magic;
uint32_t padding;
struct timeval timestamp; // #include <stdlib.h>
uint64_t cpid; // process id of the creator
int32_t count;
float fval;
char idcam[32];
int32_t origin; // enum ?
uint32_t reserved[8];
} FimgMetaData;
/*
* in memory descriptor of a floating image
* ----------------------------------------
*/
#define MAGIC_FIMG 0x00F11F00
typedef struct {
@@ -37,6 +65,7 @@ typedef struct {
float fval;
int count;
float *R, *G, *B, *A;
FimgMetaData mdatas; // added 20230912
int reserved;
} FloatImg;
@@ -51,26 +80,6 @@ typedef struct {
*/
} FimgFileHead;
/*
* new 11 mars 2022, and a lot of iterations
* around the concept of metadata for my work.
*/
typedef struct {
char magic[8]; // this is not an asciiz !
struct timeval timestamp;
uint64_t cpid; // process id of the creator
int32_t count;
float fval;
char idcam[32];
int32_t origin; // enum ?
uint32_t reserved[8];
} FimgMetaData;
/*
* we MUST look at packing and endianess problems NOW
* and we can think about a fised size of this datablock
*/
#define MAGIC_AREA51 0xA5EA0051
typedef struct {