[Originally posted by oozy on 2007-01-05 20:37:12-08]
Is it possible to list only images that have its width or height less than 700 pixel?
[Originally posted by exiftool on 2007-01-05 23:21:12-08]Sure. Try this:
exiftool -if "$imagesize and ($imagewidth<700 or $imageheight<700)" -q -t -S -filename -r DIR
where
DIR is the name of the directory containing the images.
The above command should work in a Windows shell, but if you are
using a Unix or OS X shell, use single quotes instead of double quotes.
around the -if expression.
- Phil
[Originally posted by oozy on 2007-01-06 20:20:13-08]Somehow, I am getting an error. I will show the commands and the errors then I will list the images info extarcted by 'exiftool .'
exiftool -if '$imagewidth < 600' .
File not found: $imagewidth < 600
======== ./ksi-2131.jpg
======== ./ksi-2132.jpg
======== ./ksi-2134.jpg
======== ./ksi-2139.jpg
1 directories scanned
4 image files read
hmmm! I have images with witdh < 600. Why 'file not found'?
exiftool -if '$imagesize and ($imagewidth<700 or $imageheight<700)' -q -t -S -filename -r .
File not found: $imagesize and ($imagewidth<700 or $imageheight<700)
ksi-2131.jpg
ksi-2132.jpg
ksi-2134.jpg
ksi-2139.jpg
why not?
======== ksi-2131.jpg
ExifTool Version Number : 6.00
File Name : ksi-2131.jpg
File Size : 128 kB
File Modification Date/Time : 2007:01:06 22:08:56
File Type : JPEG
MIME Type : image/jpeg
JFIF Version : 1.1
Resolution Unit : inches
X Resolution : 96
Y Resolution : 96
Image Width : 274
Image Height : 418
Image Size : 274x418
======== ksi-2132.jpg
ExifTool Version Number : 6.00
File Name : ksi-2132.jpg
File Size : 92 kB
File Modification Date/Time : 2007:01:06 22:16:58
File Type : JPEG
MIME Type : image/jpeg
JFIF Version : 1.1
Resolution Unit : None
X Resolution : 1
Y Resolution : 1
Image Width : 936
Image Height : 700
Image Size : 936x700
======== ksi-2134.jpg
ExifTool Version Number : 6.00
File Name : ksi-2134.jpg
File Size : 94 kB
File Modification Date/Time : 2007:01:06 22:04:57
File Type : JPEG
MIME Type : image/jpeg
JFIF Version : 1.2
Resolution Unit : inches
X Resolution : 300
Y Resolution : 300
Image Width : 600
Image Height : 480
Image Size : 600x480
======== ksi-2139.jpg
ExifTool Version Number : 6.00
File Name : ksi-2139.jpg
File Size : 847 kB
File Modification Date/Time : 2007:01:06 22:04:57
File Type : JPEG
MIME Type : image/jpeg
JFIF Version : 1.2
Resolution Unit : inches
X Resolution : 300
Y Resolution : 300
Image Width : 1534
Image Height : 1350
Image Size : 1534x1350
4 image files read
[Originally posted by exiftool on 2007-01-07 12:37:34-08]
You need to be running a more recent version
of ExifTool. The '-if' option was added in
version 6.50. Try downloading the most recent
version.
- Phil