On 12 oct. 2004, at 14:00, Allan Odgaard wrote:
And as said, the 'file' command can only give image dimensions for PNG and GIF pictures. It may be possible to query apple script actually, but startup time for AS is poor IMHO.
Use SIPS then. SIPS [1] is the "Scriptable Image Processing Server" and can be accessed through AppleScript AND the 'sips' command line tool.
For example, to query an image for its width and height, just do: sips -g pixelWidth -g pixelHeight the_image
To get help: sips -h
To know all available properties: sips -H
Note: I think that SIPS is only available on 10.3.
[1] http://www.apple.com/applescript/imageevents/