I've been doing some experimenting and it seems that the basic problem is with the way I was using digiKam.
In Configure - digiKam / Metadata / Behaviour there are several settings for reading and writing metadata. The really important one is : Update file timestamp when files are modified. Without this darktable doesn't know that the file has altered and will not prompt you to update the database with the "reload selected xmp files" button in the "updated xmp sidecar files found" dialogue box at start up.
Further findings from my experiments....
In the end I turned all the options on in Configure - digikam / Metadata / Behaviour and set "Write to sidecar files" to "Write to image and XMP sidecar", even though darktable really only interacts with the XMP file once it has been created. I guess this is an insurance against corrupting your image file.
digiKam has a setting in Configure - digikam / Metadata / Behaviour "If possible write Metadata to RAW files (experimental). Using Captions / Tags Description and Information tabs worked with title, caption, author, name, position and copyright all being recorded. However when I tried using the Image / Metadata / Edit All Metadata command my 10.7 MiB .ORF file was corrupted to 21.8 KiB, presumably all the image data is lost. This happens even when I try to edit only one item with all other checkbox's cleared.
When checking the .ORF files in Olympus Viewer which I had altered in digiKam, the only fault I can find is that the Lens Information which should read something like OLYMPUS 11-22mm F2.8-3.5 is messed up with a series of unreadable characters. This seems to be the Lens Model makernote, which digiKam displays correctly and darktable ignores preferring the Lens Type makernote (which reads "Olympus Zuiko Digital 11-22mm F2.8-3.5").
This may be due to the sync settings and certain fields being limited to a finite number of ASCII characters or the corruption of the makernotes.
digiKam uses exiv2 and their site Exiv2.org suggests that the closed, proprietary format of exif makernotes means that any change of an exif tag could move the makernotes field and corrupt it. Phil Harvey's Exif Tool site explains that the default behaviour of his metadata editing software is to work on a copy because of the complexities involved.
On the digiKam site digiKam Configuration a to do is described which will enable users to direct where digikam stores / retrieves tags ratings and comments.
I also found that I could use darktable's lighttable - import - image on a file already in the database to force an update, though this only seems to work once and then crashes darktable the next time you click on the button. Darktable's lighttable - import - folder does the same.
Finally, here are the locations that the software is writing data to.
When using the digiKam / Captions/Tags / Description tab:
Title is written to:
- IPTC : Object Name
- XMP : caption
- XMP : Title
Captions is written to:
- Exif : Image Description
- Exif : User Comment
- IPTC : Caption
- XMP : notes
- XMP : Description
- XMP : User Comment
- XMP : Image Description
Caption Author is written to:
- XMP : author
- XMP : Captions Author Names
When using digiKam / Captions/Tags / Information / Rights tab:
Names is written to:
- Exif : Artist
- IPTC : By-line
- XMP : Creator
- XMP : Artist
Position is written to:
- IPTC : By-line Title
- XMP : Authors Position
Copyright is written to:
- Exif : Copyright
- IPTC : Copyright
- XMP : Rights
- XMP : Copyright
When using darktable / lighttable / metadata editor:
Title is written to:
- IPTC : Object Name
- XMP : Title
Description is written to:
- Exif : Image Description
- IPTC : Caption
- XMP : Description
Creator is written to:
- Exif : Artist
- IPTC : By-line
- XMP : Creator
Publisher is written to:
Rights is written to:
- Exif : Copyright
- IPTC : Copyright
- XMP : Rights
Note darktable only writes this to the sidecar .XMP file and embeds it in any exported files processed from the RAW. digiKam can read this information and embed the data in the RAW image metadata by using Image / Reread Metadata from Image to update the database then Image / Write Metadata to Image to embed it. However this means the data is in actual fact written to more places.
Title is written to:
- IPTC : Object Name
- XMP : Title
- XMP : caption
Description is written to:
- Exif : Image Description
- Exif : User Comment
- IPTC : Caption
- XMP : notes
- XMP : Description
- XMP : User Comment
- XMP : Image Description
Creator is written to:
- Exif : Artist
- IPTC : By-line
- XMP : Creator
Publisher is written to:
Rights is written to:
- Exif : Copyright
- IPTC : Copyright
- XMP : Rights
UPDATE:
Darktable's behavior appears to have changed. Currently on v3.0.2 the metadata editor in lighttable view writes the following meta data to exported jpg's.
Title is written to:
Description is written to:
- Exif.Image.ImageDescription
- Xmp.dc.description
Creator is written to:
- Exif.Image.Artist
- Xmp.dc.creator
Publisher is written to:
Rights is written to:
- Exif.Image.Copyright
- Xmp.dc.rights
A new feature in the export tab (accessed through the cog icon next to the export button is the "edit metadata exportation" dialogue. A bit of a mouth full but a powerful tool none the less, this dialogue allows you to override the metadata editor which when combined with export presets allows the user to create different export settings for different file uses. [
Now the jpeg contains the metadata as set in the export dialogue, though notice how the xmp.dc.creator and xmp.dc.publisher entries have been appended. I believe this is because multiple instances are allowed (gnome image viewer list these as XMP IPTC - dc:creator[1], XMP IPTC dc:creator[2]
, etc).
If the general settings in "edit metadata" are all switched off the metadata is presented as shown in the dialogue, but almost nothing else is included (no camera settings, creation date or time and so on). note I haven't searched darktable to narrow down tab results this time.
The power of this feature comes in when you use it on a redefined tag with no formula (1), text (2) or one or more of the darktable variables (3). Using no formula prevents output of the meta tag and the variables are listed in the manual pdf (there are more than shown in the hint text).