ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Possible error in EXIF_FocalLengthIn35mmFilm
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

jrpcguru

USA
266 Posts

Posted - Sep 29 2016 :  21:06:16  Show Profile  Reply




I've attached a file which I downloaded today. I was not surprised that it had little Exif data recorded, but I was surprised when the EXIF_FocalLengthIn35mmFilm reported the lens was 2147483647mm. I thought you might want to inspect and see how this happened and consider whether to error trap your code to prevent reporting such large numbers. My program gave a range error which led me to discover this situation. I confirmed it with your EXIF demo program by adding the ability to report EXIF_FocalLengthIn35mmFilm.

J.R.

xequte

38615 Posts

Posted - Oct 20 2016 :  16:23:02  Show Profile  Reply
Thanks, we have investigated.

EXIF_FocalLengthIn35mmFilm (exif tag 0xa405) should be a SHORT (16 bit unsigned integer) according to the TIFF specs, but this image stores the tag as RATIONAL (a floating point value).

We have updated ImageEn to truncate floating point values to integer, when an integer is expected but a rational is found.

So now IO.Params.EXIF_FocalLengthIn35mmFilm returns 3 for this image (truncated from 3.882).

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

jrpcguru

USA
266 Posts

Posted - Oct 22 2016 :  16:50:59  Show Profile  Reply
Thanks for addressing this. Now if I only had time to install and use all of your recent updates!
Apparently the 35mm focal length for this image is just plain wrong since 3mm would be quite a fish eye view.

J.R.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: