35 printf(
"Byte order: %s\n",
38 printf(
"Parsing maker note...\n");
41 fprintf (stderr,
"Could not parse maker note!\n");
46 printf(
"Increasing ref-count...\n");
49 printf(
"Decreasing ref-count...\n");
52 printf(
"Counting entries...\n");
54 printf(
"Found %i entries.\n", c);
55 for (i = 0; i < c; i++) {
56 printf(
"Dumping entry number %i...\n", i);
57 printf(
" Name: '%s'\n",
59 printf(
" Title: '%s'\n",
61 printf(
" Description: '%s'\n",
64 if (p) { printf(
" Value: '%s'\n", v); }
71 main (
int argc,
char **argv)
74 unsigned int buf_size;
79 fprintf (stderr,
"You need to supply a filename!\n");
83 printf(
"Loading '%s'...\n", argv[1]);
86 fprintf (stderr,
"Could not load data from '%s'!\n", argv[1]);
89 printf(
"Loaded '%s'.\n", argv[1]);
91 printf(
"######### Test 1 #########\n");
99 fprintf (stderr,
"Could not load data from buf!\n");
104 printf (
"######### Test 2 #########\n");
108 printf (
"Test successful!\n");
const char * exif_byte_order_get_name(ExifByteOrder order)
Return a short, localized, textual name for the given byte order.
void exif_data_unref(ExifData *data)
ExifByteOrder exif_data_get_byte_order(ExifData *data)
Return the byte order in use by this EXIF structure.
ExifData * exif_data_new_from_data(const unsigned char *data, unsigned int size)
Allocate a new ExifData and load EXIF data from a memory buffer.
ExifMnoteData * exif_data_get_mnote_data(ExifData *d)
Return the MakerNote data out of the EXIF data.
ExifData * exif_data_new_from_file(const char *path)
Allocate a new ExifData and load EXIF data from a JPEG file.
void exif_data_save_data(ExifData *data, unsigned char **d, unsigned int *ds)
Store raw EXIF data representing the ExifData structure into a memory buffer.
Defines the ExifData type and the associated functions.
void exif_mnote_data_ref(ExifMnoteData *d)
char * exif_mnote_data_get_value(ExifMnoteData *d, unsigned int n, char *val, unsigned int maxlen)
Return a textual representation of the value of the MakerNote entry.
const char * exif_mnote_data_get_name(ExifMnoteData *d, unsigned int n)
Returns textual name of the given MakerNote tag.
const char * exif_mnote_data_get_description(ExifMnoteData *d, unsigned int n)
Returns verbose textual description of the given MakerNote tag.
const char * exif_mnote_data_get_title(ExifMnoteData *d, unsigned int n)
Returns textual title of the given MakerNote tag.
unsigned int exif_mnote_data_count(ExifMnoteData *d)
Return the number of tags in the MakerNote.
void exif_mnote_data_unref(ExifMnoteData *d)
Represents the entire EXIF data found in an image.
int main(int argc, char **argv)
static int test_exif_data(ExifData *d)