Batch extraction of Previews and Thumbnails

Started by Skippy, October 25, 2015, 01:23:03 AM

Previous topic - Next topic

Skippy

I can extract previews and thumbnails to a folder using the example pattern.
 
exiftool -a -b -W %d%f_%t%-c.%s -preview:all C:\tmp\Photos\2013-07-27_Folder

Where I am stuck is when I want to extract 6 previews from images in a folder that contains 1000 photos (*/!Lumix camera).  The reason that I want to extract the previews of the 6 images is that I could send these to a temp location and open them there.  Most photo managers have to make thumbnails starting from the beginning of the folder so if the 6 you need are near the end, you are in for a long wait. 

I am trying to get exiftool to process the subset of the photos I want and send the output to a folder that is likely to be somewhere entirely different from the input path. 

I have been attempting to use the -@ method but can't get it to work. 
I have tried with just a list of file names in the arg.txt file and then the balance of the arguments on the command line.

exiftool -@ c:\tmp\PhotoFileList.txt -b -preview ">" C:\tmp\%f_%t%-c.%s

I have tried many combinations and I get error messages such as
Output file -previewimage already exists for C:/tmp/%f_%t%-c.%s

Currently I have a single filespec in the arg.txt file but the output is confusing
    1 directories scanned
    2 image files read
  175 files could not be read
    0 output files created


I have also tried setting the hidden file attribute on all the photos that I do not want.  This is very fast.  However all the photo managers I am using ignore the attribute and show the photos anyway.  Exiftool also processes these photos.  Is there some filing system attribute that can be set to prevent exiftool from reading some of the files in a directory?  If this was the case, I could use the directory scanning cmd line.

Is it possible to pass a list of files to exiftool and have the previews extracted to a directory that varies with input image?

S




Phil Harvey

The shell redirection (>) doesn't work with the ExifTool formatting feature (%f etc.).

You should use the -W option like your last command.  Also, it sounds like your .txt file might have some problems.  If you could attach it to your post I will take a look.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).