From: Jan P. <pa...@pi...> - 2008-11-06 21:20:50
|
Hi, > Now how do I update or add exif information if not available? > I assume I would have to create a new exif entry with exif_entry_new() > Not sure how to fill it properly though. > For example there is no exif_entry_set_value(). Will I have to modify > the struct directly? When the entry doesn't exist yet, you should do something like this: 1) e = exif_entry_new() 2) do something similar that exif_entry_initialize does for e.g. EXIF_TAG_EXIF_VERSION. Here you will have to set the correct value(s) using something like exif_set_short(e->data, exif_data_get_byte_order(e->parent->parent), val); 3) exif_content_add_entry(ifd, e); 4) exif_entry_unref(e); Hope this helps. -- Jan |