metadata-extractor
metadata-extractor copied to clipboard
Canon CR3 files reporting incorrect Focus Distance values
Per this sample image, the values below show as zero, whereas the correct values are reported by exiftool
metadata-extractor
[Canon Makernote] Focus Distance Upper - 0
[Canon Makernote] Focus Distance Lower - 0
exiftool
Focus Distance Upper : 0.95 m
Focus Distance Lower : 0.94 m
I'd be happy to help out on this given some guidance as to where issue is occurring.
Those tags are defined in:
https://github.com/drewnoakes/metadata-extractor/blob/5754a0d33659e6b1e9d8f35cf24bc03e0fbaf1b6/Source/com/drew/metadata/exif/makernotes/CanonMakernoteDirectory.java#L348-L349
Certain Canon makernote values have logic to present their values in:
https://github.com/drewnoakes/metadata-extractor/blob/5754a0d33659e6b1e9d8f35cf24bc03e0fbaf1b6/Source/com/drew/metadata/exif/makernotes/CanonMakernoteDescriptor.java#L47
It looks like there's no specific handling for those tags, so one idea would be to add them.
However I'm unclear whey we're showing a zero here. The first step would be to run in a debugger and identify what value was read from the backing data. It's possible the code that reads data into the CanonMakernoteDirectory
is faulty here.
Thanks @drewnoakes, I did run a debugger through and saw they were zero but didn't get further than that due to time.
I'll do a deeper dive shortly.