Hi, I am trying to work with the android app "F-Stop" which seems to use the Adobe Java library to read metadata. Now getting Metadata from my Images and movies into the sidecar xmp's was easy, but after a longer discussion with the create of F-Stop it seems that those xmp's are invalid.
The sidecars I created were like this (minimal example i used for testing):
<?xpacket begin='' id='W5M0MpCehiHzreSzNTczkc9d'?>
<x:xmpmeta xmlns:x='adobe:ns:meta/' x:xmptk='Image::ExifTool 8.60'>
<rdf:RDF xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
<rdf:Description rdf:about=''
xmlns:exif='http://ns.adobe.com/exif/1.0/'>
<exif:DateTimeDigitized>2013-03-13T17:08:03+00:00</exif:DateTimeDigitized>
<exif:DateTimeOriginal>2013-03-13T17:08:03+00:00</exif:DateTimeOriginal>
</rdf:Description>
<rdf:Description rdf:about=''
xmlns:xmp='http://ns.adobe.com/xap/1.0/'>
<xmp:CreateDate>2013-03-13T17:08:03+00:00</xmp:CreateDate>
<xmp:ModifyDate>2013-03-13T17:08:03+00:00</xmp:ModifyDate>
</rdf:Description>
</rdf:RDF>
</x:xmpmeta>
<?xpacket end='w'?>
While the the app creator suggested that it has to look like this:
<?xml version="1.0" encoding="utf-8" ?>
<x:xmpmeta xmlns:x="adobe:ns:meta/">
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="uuid:08a92b8d-4e6f-5da0-6950-910affbadd6b" xmlns:dc="http://purl.org/dc/elements/1.1/">
<dc:subject>
<rdf:Bag>
<rdf:li>Brina</rdf:li>
</rdf:Bag>
</dc:subject>
</rdf:Description>
<rdf:Description rdf:about="uuid:08a92b8d-4e6f-5da0-6950-910affbadd6b" xmlns:xap="http://ns.adobe.com/xap/1.0/">
<xap:Rating>5</xap:Rating>
</rdf:Description>
</rdf:RDF>
</x:xmpmeta>
The strange things to me in his example are: I have never ever heard of XAP which google revealed is the old Adobe standard for XMP and I have never before seen this syntax for the subject.
Is exiftool capable of create Adobe compatible sidecar files? Any ideas on how I could accomplish this without a Windows or Adobe Suite License??
tia,
Jörg
Hi Jörg,
Re-reading the XMP specification, I can't find anywhere that says you need an XML header for an XMP file, or that an xpacket wrapper can't be used in an XMP file. So I don't think the first format is invalid, but I have sent an email to the head of XMP at Adobe to see what he says.
As a work-around, you can get ExifTool to write the desired format by starting with this blank sidecar file:
<?xml version="1.0" encoding="utf-8" ?>
<x:xmpmeta xmlns:x="adobe:ns:meta/">
</x:xmpmeta>
If you use ExifTool to add metadata to the above file, the XML header will be preserved and no xpacket wrapper will be added.
- Phil
Edit: My email to Adobe bounced, so it looks like I have lost my XMP contact at Adobe. They really don't seem to retain their upper management for very long. :(
Would it be possible for exiftool to create this sidecar file from scratch without needing the user to create it first the write to it?
Take a look at this doc page (http://www.exiftool.org/metafiles.html).
Quote from: StarGeek on November 21, 2014, 03:53:10 PM
Take a look at this doc page (http://www.exiftool.org/metafiles.html).
The nearest I have found is the following but it always gives the warning but still makes the XMP file, is this normal or just a side affect.
./exiftool -use MWG -@ exif2xmp.args -@ iptc2xmp.args -Composite:State=test output.xmp
Warning: No writable tags set from output.xmp
1 image files updated
You haven't specified a source file for the EXIF and IPTC tags. You need to do something like this:
exiftool -use MWG -tagsfromfile input.jpg -@ exif2xmp.args -@ iptc2xmp.args -Composite:State=test output.xmp
- Phil
And how can I do it without specifying a source file, I want to create the XMP file from scratch from data in my database.
Should I just ignore the Warning or supply a default XMP file as the input then modify it as required to the output?
You need a source file if you are copying tags with "-@ exif2xmp.args". If you want to generate an XMP file from scratch, you should drop these options. Also, "-use MWG" isn't very useful when writing only XMP. So try this:
exiftool -xmp:State=test output.xmp
- Phil
ok, ile do some jiggery pokery to my code to correct this.