• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Open the Import prompt from NodeJs or Python

New Here ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

Hi all!

I am building an app which does some preprocessing on the RAW and JPEG images before the users import it into Lightroom.

Is there a way I can automatically import the images from my app into Lightroom classic (assuming that it's installed on the user's machine)

If not, then is there a way with which I can open Lightroom and then the import prompt from my app?

For reference, this is the dialog I am talking about.

Screenshot 2020-11-17 at 7.04.25 PM.png

I am currently using Python and NodeJs in my app.

TOPICS
SDK , Windows

Views

748

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

What exact Pre-Processing are you doing to the images before they get imported into LrC?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

Hi, thanks for your reply!

I'm adding some keywords to the exif data of images (it would be xmp for RAW and modifying the metadata for JPEGs)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

Import into Lightroom Classic is not always a simple or 'neutral' event since (under LR's control and as the user selects) the images may be appropriate to copy, move or leave in place - they may be DNG converted - the files may be renamed - a duplicate copy may be archived elsewhere - batch keywording and metadata preset and develop preset may be applied. So I guess one question is, what KIND of import should your app be achieving and how would it make that happen. That;s besides the possibility that LR may be used with more than one Catalog, which (regardless of the usual arguments supporting a single catalog, which we can take as read here) some people will do.

 

Perhaps another approach may be to employ a watched folder, set up previously in LR, where newly added images will auto-import the moment LR sees them. However this watched folder is unlikely to be the best permanent location for these images to live in, so that stores up some extra work. And this approach will forgo LR's ability to fully take over the work of folder-filing images, e.g. directly into a consistent capture-date scheme.

 

So, looking at either a 2-stage process of altering metadata then doing a standard LR import (images can be drag-dropped onto LR as an alternative)

 

OR there is an option to write out metadata externally from LR after import (so as to preserve whatever edits / default processing have happened during that or subsequently), invoke an external tool that changes this XMP metadata on disk, then read this altered metadata back into LR.

 

I recall a LR plugin called LensTagger worked like this - mainly used to update/correct Lens descriptive metadata, which could otherwise not be changed within the LR metadata panel, though I think some other kinds of metadata could be addressed the same way also.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

That makes sense.

Is it possible for me to open just the import popup (and not perform any import)?

That way I can open the source folder and Lightroom's import popup and ask the users to simply drag and drop the opened folder into lightroom.

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

“I'm adding some keywords to the exif data of images (it would be xmp for RAW and modifying the metadata for JPEGs)”

 

 

Why does this have to be done BEFORE import?

 

Why can't it be done at Import, via a Ligthroom Classic preset?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

It can, but my app does some backend processing as well which is a little tricky to do withing the restricted plugin environment

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Nov 17, 2020 Nov 17, 2020

Copy link to clipboard

Copied

LATEST

The LR SDK for plugins has a number of facilities you might use in a plugin installed into LR:

 

catalog:addPhoto() adds photos (imports them) to a catalog

 

catalog:triggerImportUI (path) opens the Import dialog, with "path" selected as the source

 

catalog:triggerImportFromPathWithPreviousSettings (path) starts an import from "path", using the previous import settings

 

You external app can communicate with LR plugin using a lightroom:// URL, which will pass the URL parameters to your plugin.  Or the plugin could listen on a socket using LrSocket.

 

You can download the LR SDK from here:

https://console.adobe.io/downloads 

 

Expect to spend at least 8 - 20 hours getting up to speed on the SDK and the Lua language, though.

 

[Use the blue reply button under the first post to ensure replies sort properly.]

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines