FullMetaExport

FullMetaExport – Lightroom Plugin

When I try to export image from RAW to JPG, Lightroom only keep the Meta in its XMP format.  When I search on the web, I found there is a very useful tool, ExifTool.  ExifTool can handle all meta very well.  So, I make a simple Lightroom plugin, and a GUI, that will create a command to run ExifTool.

It needs ExifTool in order to work.  I don’t include ExifTool in the file.  You need to download it separately.  Please remove (-k) from the file name.

From version 20120818, Mac is supported.

This is a 1st beta.  It may have a lot of bugs.  Use on your own risk.

Download:
Version 20120108 – bug fix and better way to display status info
Version 20120518 – Download – Separate all strings. Create TranslatedStrings_en.txt.  Minor changes.
Version 20120813 – Add an option to generate temporary args file. When using args file option, one tag per line is required, and no quotes for options. If using command line option, quotes is required for special characters, such as and space. Add save and delete tags list. Minor changes.
Version 20120818 – Add Mac support.  Rewrite some codes for better support quote and un-quote.  Make more room for tags.  And many more.
Version 20120826 – Download – Just fixed the quoting problem.

Examples:

1. one of major motives for me to create this plugin is to copy the original Exif to the new images.

-overwrite_original -tagsfromfile <SrcImg> -all:all <DestImg>

For my Nikon images, the new exported images will include many information, such as focus points.  ViewNX 2 will be able to show the focus points for the new exported images.  But, there is one exceptions, the images size must not be altered.

I like to keep -overwrite_original in all time.  With it, Exiftool will not create a backup file, otherwise, it will create two images, for every export.

<DestImg> should be at the end of parameters in all time, too.  We want to modify the new exported files.

Warning: Using <SrcImg> with care.  If you put it in the wrong position, the original files might be changed.  If you don’t have a backup, you will not able to recover them.

2. If you just want to remove some Exif information, for example, GPS.

-overwrite_original -exif:gps= <DestImg>

51 Responses to FullMetaExport

  1. chaoliu12 says:

    FullMetaExport – Lightroom Plugin
    Download Link:
    Moved to body of this page.

    Version 20110924 – fix the multiple images process problem.

  2. Pingback: Lightroom plugin for ExifTool

  3. yoman1 says:

    Thanks awesome plugin.

  4. naike says:

    I have this as my code:

    -overwrite_original -tagsfromfile -all:all -exif:software=^ -exif:gps=^ -xmp:all=^ -icc_profile:all=^ -jfif:all=^ -photoshop:all=^ -exif:copyright=”© asdf” -exif:artist=”asdf” -exif:ownername=”asdf” -makernotes:all=^ %*

    But it only removes exif:software tag from the first file, but all others it leaves it there.

    • chaoliu12 says:

      I’m new to Exiftool. We can try to work it out. Which screen do you try to use? The export one or the GUI?
      For the parameters in export screen, there are two special parameters, <DestImg> and <SrcImg>.
      <DestImg> should be used for the image which will be modified. In most case, it should be in the parameter list.
      <DestImg> is represent the original image.

      I see that you use -tagsfromfile, but missing the source file. Try -tagsfromfile <SrcImg>. Or try these parameters
      -overwrite_original -tagsfromfile <SrcImg> -all:all -exif:software=^ -exif:gps=^ -xmp:all=^ -icc_profile:all=^ -jfif:all=^ -photoshop:all=^ -exif:copyright=”© asdf” -exif:artist=”asdf” -exif:ownername=”asdf” -makernotes:all=^ <DestImg>

      • chaoliu12 says:

        I figure out that you just remove all meta and set the copyright information. So you don’t need -tagsfromfile and -all:all, too. Try this one
        -overwrite_original -exif:software= -exif:gps= -xmp:all= -icc_profile:all= -jfif:all= -photoshop:all= -exif:copyright=”© asdf” -exif:artist=”asdf” -exif:ownername=”asdf” -makernotes:all=^ <DestImg>
        May be this one is better
        -overwrite_original -all:all= -exif:copyright=”© asdf” -exif:artist=”asdf” -exif:ownername=”asdf” <DestImg>

    • chaoliu12 says:

      There is a bug in it. You can re-download it, and replace the old one. I just try it on mine images. It is fine, expect for ©.

  5. Edmund Fung says:

    Used for 2 days then completely broke. The “run” button does nothing anymore. Got ideas?

    • chaoliu12 says:

      What is it in the last text box? The run button will run the command line in it. Do you mind copy it to me, so I can check it.

      • Edmund Fung says:

        Thanks for replying!

        cmd /c start “exiftool” /D “E:\edd.stuff\stuff.jpg\2012\2012-01-04″ “C:\Program Files\Adobe\Adobe Photoshop Lightroom 3\FullMetaExport.lrdevplugin\exiftool.exe” -overwrite_original -k -LensMake=”Minolta” -LensModel=”Minolta Rokkor-x 50mm f/1.7″ -Lens=”Minolta Rokkor-x 50mm f/1.7″ “E:\edd.stuff\stuff.jpg\2012\2012-01-04\IMG_6462.JPG”

  6. chaoliu12 says:

    The command line looks fine. Do you see the exiftool window? If not, try to just run the command in cmd.exe. Press Win+R, copy and paste the command, cmd /c start “exiftool” /D “E:\edd.stuff\stuff.jpg\2012\2012-01-04″ “C:\Program Files\Adobe\Adobe Photoshop Lightroom 3\FullMetaExport.lrdevplugin\exiftool.exe” -k, start from cmd to -k, press Enter. You should see the exiftool window. If any error, you having problem with exiftool. Else, there are some problem with my plugin or lr.

  7. Edmund Fung says:

    It says cannot find “exiftool”. Did I need to copy the exe to a directory too? Thanks for following up on this btw.

  8. chaoliu12 says:

    One thing I forgot to tell you, copy the command line from the GUI, not from the web. The string from the web may have problem with quotes(“). You can put the exiftool.exe into any folder. Just keep the exiftool field having the full path and quotes it if the path have spaces. The easy way to do it. Go to plug-in manage -> Full Meta Export -> Command Line For exiftool, click the select button to select the executable file.

  9. Edmund Fung says:

    Well my command was too long for the win + r window so exiftools displayed file not found so I shortened it and it worked. I don’t know much about the coding of the program but it seems like the run button just isn’t activating exiftool. I tried uninstalling the plugin and such but that didn’t fix it either.. :(

  10. chaoliu12 says:

    I need more time to rewrite the code to enable the debug function to get more info.
    I’m happy to help you. Please be patient.

  11. Edmund Fung says:

    :( that didn’t work. Another thing, I didn’t copy the exe to the directory but it never warned me about not finding the exe; however that didn’t work either. One more thing which I think may be the problem. I tried running the exiftool by itself via command prompt and I got this weird Error Running More message and a path to a log file I can’t get to.. it has two \\ in the path. Any other ideas? Really like to use your plugin again!

  12. chaoliu12 says:

    1. I put the exiftool.exe in different folder, too. Work fine for me. The last version had an bug, it didn’t show any errors even it failed. After I updated the code, it should popup an error message if it failed.
    2. That’s a good try, running exiftool in command prompt. You got an error, that means you have problems with exiftool. I never got an error with exiftool, yet. Have you tried to google it? Have you try to delete the exiftool cache folder in %temp%?
    3. What do you mean has two \\ in the path? Would you give me more detail?
    4. To test my plugin.
    a. Check edit check box,
    b. Type
    cmd /c start cmd
    into the command text box
    c. Uncheck edit check box
    d. Click run buttom
    If you see a command prompt window, it means my plugin works fine.

  13. chaoliu12 says:

    I really have no idea. There are something causing LrTasks.execute() failed, so you didn’t see anything ran after click the run button. This is more in Adobe side. I can’t figure out why.
    For ExifTool problem, I google it. one has the same problem. This is the link
    http://u88.n24.queensu.ca/exiftool/forum/index.php?topic=3393.0
    I’m not sure you have problem with other program or not. Maybe these problems are linked to the same one. Sorry I can’t help you.
    Other thought, create a different user name. Login with the new user name. If have no problem that means the profile is corrupted.

  14. Edmund Fung says:

    Hmmm, alright. I’ll tinker around with it and see it I can get it to work. If so, I’ll post back. Thanks for all your help!!

  15. Edmund Fung says:

    I turned on the debugging function on Lightroom in the plugin manage and when I hit run i get “Failed to start Exiftool”.. don’t know if that’s any help

  16. chaoliu12 says:

    There are part of my code in the action of the run button

    LrTasks.startAsyncTask( function()
    -- exiftoolCmd.value is the command line
    local result = LrTasks.execute( exiftoolCmd.value )
    if result ~= 0 then
    myLogger:trace( "Error: ", result, "Failed to Start ExifTool" )
    LrDialogs.message('Error: ' .. tostring(result), "Failed to Start ExifTool\n\n" .. exiftoolCmd.value, 'warning')
    else
    myLogger:trace( "Command succefully started" )
    end
    end, "StartExecuteCmd")

    Doesn’t matter you enable the debug function or not, you should see a popup say “Failed to Start ExifTool” if LrTasks.execute failed.

    As tested in my pc, if LrTasks.execute throws an error, then its following codes wont be processed, then you don’t see any message, just nothing show up.
    If you see “Failed to Start ExifTool”, that means LrTasks.execute() is fine and it returns a result. So the problem is the command line tried to be executed. Then can you try to copy the whole command line and paste into the command prompt to test it?

    Back to the testing as before, just type “start cmd” without quotes in the command text box, and hit run, you should see a command prompt window. Otherwise, it still a LrTasks.execute problem that I can’t figure out why.

    LrTasks.execute will run a program in background, you can’t see any windows. That’s why it need “start cmd” in text box to bring up anthor command prompt. If you just type “cmd” in the command text box and hit run. then open task manager, you should see two command prompt running in background. You have to end them from the task manager.

  17. Edmund Fung says:

    Ahhh, I think that’s the fix. Start cmd works so I just tacked on “start” to the command line command for what I wanted to do with exiftool and it worked!!!

    Thanks a bunch!!

  18. chaoliu12 says:

    I just update the plugin and fix a bug from export module and get rid of cmd /c from the command line. Please re-download it. Thanks.

  19. Hans says:

    Hi,
    installed you plug-in, but I don’t know about the next step!
    I know ExifTool quite well and used it a lot, but I don’t see how to use it with your plug-in, I am puzzled. I never got to see the ‘ExifTool Gui Popup’ nor the ‘The export post processing provider’.
    Please provide instructions how to use this tool.

    • chaoliu12 says:

      To open an ExifTool Gui Popup,
      1. go to
      File -> Plug-in Extras -> ExifToolGui
      or
      Liberay -> Plug-in Extras -> ExifToolGui
      2. Select the option as needed
      3. Click Generate Command
      ExifTool Parameters text box will show the ExifTool Patameters which will be processed.
      The text box above Generate Command will show the complete command line that will be processed by Run ExifTool Command button.
      4. Click Run ExifTool Command button

      To use export post processing provider
      1. Select the image to be exported
      2. In the Export window, Select ExifToolProvider from Post-Process Actions, click Insert.
      3. Type ExifTool parameters into big text box in Export Meta using ExifTool session.
      4. Change other export settings as needed
      5. Click Export.

  20. Hans says:

    Thanks for the heads-up. Of course, that’s where one would look first, except that the menu option for ‘ExifToolGui’ was not there after installation and restart. Now by whatever magic it’s there – and it works really well. Thanks for this great tool to be used within Lightroom. Keep the good work going.

    By the way there is another great tool named equally ‘ExifToolGui’ by Bogdan Hrastnik
    http://u88.n24.queensu.ca/~bogdan/
    It runs standalone in Windows environments.

  21. rubin110 says:

    Hi there. Thanks for this plugin, I rather appreciate it. Currently I’ve got going a series of bash scripts to do a bit of pre-metadataing (film camera make, model, and some time stamp tweaks) before I actually import into Lightroom. I might need to rethink a bit of that now with your plugin.

  22. Pete says:

    Hi,

    very useful plugin, thanks! I just realized that Dirk Essl’s LenTagger plugin is based on yours (http://www.essl.de/wp/2012/05/24/lenstagger-now-with-analog-camera-film-support/).
    I made a comment on his site about the limitation on Windows, that the generated command line can get too long very quickly. There is one possible way to avoid that.

    It seems that the “-@ FILE” option of exiftool reads all the command line arguments from FILE. This option could possibly be used to create a TEMPFILE with all the options *and* image file names in the plugin (or at least the file names) and then run exiftool with that -@ FILE option. That would let us run the tool on hundreds of images at one strike (something I’d really need). You could still display the generated command as currently, but the implementation of it would be via this temporary file (which can be deleted upon successful execution).

    Also, you could (at least as an option) invoke the “read metadata from file” action for the images that were passed to exiftool (the plugin has the list) upon successful execution. That would eliminate the extra step of having to do it manually.

    Please consider those features! Thanks,

    Peter

  23. David Todd says:

    In exiftool, the following command will add one second to datetimeoriginal as it processes each file:

    -DateTimeOriginal+<0:0:$Filesequence

    I can't get this tag to run in the FullMetaExport.

    David

  24. David Todd says:

    It turns out that the tag as I had written it was correct with one exception. Apparently, tags that use the “redirect” symbol (“”) have to be enclosed in quotes. Exiftool GUI must add the quotes automatically, which is why it worked without quotes there. The correct format to add a number representing the sequence in which files are processed to seconds is as follows: “-DateTimeOriginal+<0:0:$Filesequence" (including quotation marks). This works fine in FullMetaExport, which greatly simplifies my workflow for scans. Thanks very much!

    David

    • David Todd says:

      P.S. I may not have been clear about what I was trying to do. I was not trying to add one second to all of the selective files (your example). I was trying to reflect the sequence in which the selected files were processed by adding the value of a sequence counter to seconds (i.e., add 1 second to the second file, 2 seconds to the 3rd file, 3 seconds to the 4th file, etc.). I work with a lot of scanned images, and this allows me to order the images by time, even when I am estimating the time that the images were originally created.

      • chaoliu12 says:

        I just update the plugin. It has an option to generate the args file, then process it. It may be easy to debug because you can manually change the file before run it.

    • chaoliu12 says:

      Yes. I use command line, so quote is required for special characters, include space.

  25. Pete says:

    Hi,

    this is great development and I can see it now how tremendously helpful it will be. Currently there are some quirks, though. Here a couple of observations:
    1) I got confused to start with by the the same version number as before (20120518). Could you update that as it suggests a date that is obviously incorrect.
    2) I understand that there one can operate the plugin now in three ways
    A) as before (generating command line)
    B) using a temporary ARGS file
    C) using an explicit ARGS file

    Using A) is not stable on my system (LR 3.6 on Vista) anymore since this update. Many times, when I generate the command line, I get a list of files in which the file name names are NOT quoted and are NOT separated by spaces either. When I switch back and forth between A) and C) a couple of times, sometimes the problem goes away and I do get a proper list of file names (quoted and separated with a space)

    Sometimes (and I can not say when this occurs but it happened to me a couple of times), the plugin gets confused about the selected list of images. If I am in a collection and a put and additional filter on top and end up with just a few images for which I’d like to run the plugin, the actual run is on all the images in the collection NOT just on the few that passed the filter.

    B) and C) do not behave identically. Whereas the C) (the explicit one) has the arguments on the same line (not one line each, as required) and gets confused about the file names too (not separated, as above), the B) (temporary) file seems to get it right most of the time. Sometimes though, when I look at it, it is empty. I could not figure out when this happens.

    In the C) case the file must already exist as it seems. This is unusual behavior. One would expect to be able to navigate to a folder and enter a file name. If it does not exist, it should be created by that name in that folder.

    I found that the current version work reliably only if option B) is used.

    Further comments:

    1) the plugin always specifies a folder where it starts up per default. This is not very useful in Lightroom, as one uses more often that not a collection and the images are not in the same folder anyway. The file names generated are absolute (full path) anyway, therefore this information is not really needed and just takes up space from the total command line length. Please consider switching it off and possibly give an option to generate it if needed.

    2) The correct past participle of “write” is “written”, not “writed”, you might want to consider to do a global search and replace on that one.

    3) The plugin seems to launch the the default windows editor for text files, which does not have impressive capabilities. Many of us use other editors (like notepad++). I suppose one could open the ARGS file (if it is clearly a text file, such as when it has *.txt extension) with the user set application specified for that file type by association.

    3) Again, please consider running (at least as an option) an automatic metadata read on the images selected, so that one does not have to do that step manually after the plugin completes.

    Thank you for working on this plugin. It is already useful but it will be tremendously useful with the new feature.

    Cheers, Pete

    • chaoliu12 says:

      Thank you very much for everything!
      I just rolled out the update hastily. For the next update, I hope I can do more testing before rolling it out.

    • chaoliu12 says:

      A) Command line is not properly quoted or/and spaced.
      I’m not sure you talking a same issue or not. If switching between command line mode and args file mode, the parameters may have to updated manually. I’m having a difficulty to write a code to update them automatically,

      B) and C) do not behave identically
      I need more time to debug it.

      C) not able to select a non-existing file
      I forgot it. by default, Exiftool, -@ is import only, so I use runOpenPanel. I’ll add runSavePanel in next version, so it will be able to create a file.

      3) open Args file in other programs.
      It is only the temporary option. Because every windows have notepad, so it would cause less problem. I use Notepad++ most time. I will add an option to choose the programs.

  26. David Todd says:

    Many useful developments in the last version, but the effort to quote arguments with special characters is creating more problems than it is worth. Date/time values have to be quoted because of the space, e.g.

    -datetimeoriginal=”1969:12:25 00:00:00″

    FullMetaExport is now adding quotes to the entire argument, as follows:

    “-datetimeoriginal=”1969:12:25 00:00:00″”
    This produces an error, and if you leave off the original quotes in the argument, FME leaves off the time value.
    Could we have a version that has the other changes, but not the quotation effort, until that gets worked out?

    • chaoliu12 says:

      I just update the plugin. Now, it should handle the case. In addition, -datetimeoriginal=”1969:12:25 00:00:00″ can be written as “-datetimeoriginal=1969:12:25 00:00:00″. Anyway, either case, the newer version takes care it.

  27. JoniR says:

    Hi, Is there possible to run exiftool twice at one export with different parameters?
    Today I am exporting images but there is no way to mark original picture to “exported”.
    My command for exported pictures are now:
    -overwrite_original -tagsfromfile -all:all –Orientation -keywords=”Exported from Lightroom to Disk” -xmp:Label=Blue
    So I am thinking is there possible to run second command like:
    -overwrite_original -keywords=”Exported from Lightroom” -xmp:Label=Green

    • chaoliu12 says:

      As my understanding, you want to using exiftool to update both exported and original images. ExiftoolProvider only support single line command and it will be called only once. I’m still not very family with Exiftool. Whether Exiftool support to update multiple images with different parameters in a single command, my guess is no, so it’s not possible to do what you want in single step. So you have to do it in separated steps. Use the first command to update exported images, then update the original images using LR build-in function or running the second command in ExiftoolGUI.

  28. Mark says:

    Hi, Using Mac OS X, what is the file path name for exiftool that I need to add into the plugin? The Exiftool website just says it is in /usr/bin/ So what is the file path? Does Exiftool have an extension like it does in windows?

    Thanks

    • chaoliu12 says:

      If it is in /usr/bin/, then the path is /usr/bin/Exiftool.
      In Mac, it doesn’t have extension. And it is case sensitive.
      Before enter it in Lightroom, you can try it in terminal.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s