writing a caption to a jpeg file so that digikam will recognize it

Jim Gomi gomi at mailup.net
Tue Dec 27 18:52:31 GMT 2016


On Tue, 2016-12-27 at 12:59 +1100, Simon Cropper wrote:
> On 27/12/16 08:35, Jim Gomi wrote:
> > How do I write a caption into a JPEG file's metadata in such a way
> > that
> > digikam will see it and recognize it as a Caption?
> > 
> > I would like to do this using some scriptable method such as a
> > python
> > module or a command-line utility like exiftool or exiv2.
> > 
> > 
>  
> Hey Jim,
> 
> Back engineer the tag data.
> 
> Create a caption in digikam, save the data to the JPG file (normal
> behaviour for digikam; see settings if this does not already happen)
> then use exiftool (windows) or exiv2 (linux) to extract the metadata
> and see what tag it was stored.
> 
> -- 
> Cheers Simon


I tried that. E.g., if I extract the metadata using
exiv2 ex IMG_0910.JPG
then I get a bunch of complicated stuff including:

<rdf:li xml:lang="x-default">This is a picture of a person</rdf:li> 
<exif:UserComment> <rdf:Alt> <rdf:li xml:lang="x-default">This is a
picture of a person</rdf:li> </rdf:Alt> </exif:UserComment>
<dc:description> <rdf:Alt> <rdf:li xml:lang="x-default">This is a
picture of a person</rdf:li> </rdf:Alt> </dc:description>

So it seems that the caption has been placed in multiple tags, and I
don't know how to write to those tags.







More information about the Digikam-users mailing list