ExifTool Forum

ExifTool => Developers => Topic started by: AlessandroA on December 19, 2016, 06:40:09 AM

Title: Different ResolutionUnit Numeric Codes between TIFF and JPEG files
Post by: AlessandroA on December 19, 2016, 06:40:09 AM
Hi,

I'm using Exiftool 10.36 (Mac Version) to extract, in PHP output, image metadata from TIFF and JPEG files.
The command is: "exiftool -php -n $img".

Why, when -n (numeric values) option is specified, the [resolutionUnit] is expressed in different ways?
For TIFF is: [ResolutionUnit] => 2
For JPEG is: [ResolutionUnit] => 1

Switching to verbose mode the "inches" value is exported for each format.

Thanks,
A.




Title: Re: Different ResolutionUnit Numeric Codes between TIFF and JPEG files
Post by: Hayo Baan on December 19, 2016, 07:03:00 AM
It's because in a JPG, 1 means inches and in a TIFF, 2 means inches :)
Title: Re: Different ResolutionUnit Numeric Codes between TIFF and JPEG files
Post by: Phil Harvey on December 19, 2016, 07:10:14 AM
Yes.  As Hayo mentioned the EXIF and JFIF encodings of ResolutionUnit are different.

- Phil
Title: Re: Different ResolutionUnit Numeric Codes between TIFF and JPEG files
Post by: AlessandroA on December 19, 2016, 07:14:04 AM
Thank you.  :-[