Making the switch from Lightroom

Yes, I think so.

Thanks. Changes made.

Hi Pascal, making some change on the code with traces it seems the code is run twice. Am I wrong ? Is that intentional ?

  /* Lr 7.0 CC (nodes) */
  snprintf(expr, sizeof(expr), "//%s:*", names[i]);
  _handle_xpath(dev, doc, imgid, xpathCtx, (const xmlChar *)expr, &data);

  /* Lr up to 6.0 (attributes) */
  snprintf(expr, sizeof(expr), "//@%s:*", names[i]);
  _handle_xpath(dev, doc, imgid, xpathCtx, (const xmlChar *)expr, &data);

Yes, IIRC a first time when importing from lighttable (getting title, starts…) and a second time with dev data.

Edit (rewrite): I’d forgotten this point. Does that means that as long as the image has not been opened in development, dev data are not retrieved ?

Hi Pascal,
For lr import I see two missing functions:

  • Get treatments from jpg & tif xmp data
  • Retrieve virtual copies (virtual copies are not in xmp data but snapshot data are. So making a snapshot of virtual copies would give access to them)

Is there already any plan to do this ?
Is the dt routine to retrieve xmp data from xmp file the same as to retrieve embedded xmp data in jpg file ?
From your standpoint how you would do that ? Any advice ?
Thanks

I think I have found the answer for this.
If jpg and tif files have an xmp sidecar file with development data, dt imports them as well ! Very, very well done ! :grinning:
To build these xmp files, the following command does the job:
exiftool -ext jpg -ext tif -overwrite_original -tagsfromfile @ -all:all -srcfile %d%f.xmp -r DIR
with DIR = images’ root folder.

Remain the virtual copies …

IIRC virtual copies are only in the Lr database, there is no XMP. So no easy.