display reserved words of metadata

This commit is contained in:
tTh 2024-04-08 12:35:51 +02:00
parent bdfb3e279d
commit 7586423d23
1 changed files with 12 additions and 1 deletions

View File

@ -16,7 +16,7 @@
int verbosity;
enum comId { C_timestamp, C_daytime, C_count, C_fval, C_cpid, C_origin,
C_idcam, C_all };
C_idcam, C_reserved, C_all };
typedef struct {
char *name;
@ -31,6 +31,7 @@ Cmd Cmd_list[] = {
{ "fval", C_fval },
{ "origin", C_origin },
{ "idcam", C_idcam },
{ "reserved", C_reserved },
{ "all", C_all },
{ NULL, 0, }
};
@ -73,6 +74,14 @@ for (n=0, cmd=Cmd_list; cmd->name; cmd++) {
fputs("\n", stderr);
}
/* --------------------------------------------------------------------- */
int show_reserved(FimgMetaData *pmd)
{
int foo;
for (foo=0; foo<8; foo++) printf("%08x ", pmd->reserved[foo]);
puts("");
return 0;
}
/* --------------------------------------------------------------------- */
int get_print_metadata(char *fname, char *command)
{
int foo, action;
@ -104,6 +113,8 @@ switch(action) {
printf("origin 0x%x\n", metadata.origin); break;
case C_idcam:
printf("camid \"%s\"\n", metadata.idcam); break;
case C_reserved:
show_reserved(&metadata); break;
case C_all:
fimg_show_metadata(&metadata, fname, 0); break;
default: