Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix reading arrays of Float64 in TIFF files #548

Merged
merged 1 commit into from
Jul 30, 2021

Conversation

fclof
Copy link
Contributor

@fclof fclof commented Jul 29, 2021

Double64 should take 8 bytes, instead of 4.

I found this bug when I tried to read tags from a geotiff.

The original data was
7B 14 AE 47 E1 7A 84 3F ----- 0.01 index 0 - 7
7B 14 AE 47 E1 7A 84 3F ----- 0.01 index 8 - 15
00 00 00 00 00 00 00 00 ----- 0 index 16 - 23

but metadata-extractor read it like this:
7B 14 AE 47 E1 7A 84 3F ------- index 0 - 7
E1 7A 84 3F 7B 14 AE 47 ------- index 4 - 11 [should be 8 - 15]
7B 14 AE 47 E1 7A 84 3F ------- index 8 - 15 [should be 16 - 23]

Double64 should take 8 bytes, instead of 4. I found this bug when I tried to read tags from a geotiff.
@drewnoakes
Copy link
Owner

@drewnoakes drewnoakes changed the title Fix bug in TiffReader.java Fix reading arrays of Float64 in TIFF files Jul 30, 2021
@drewnoakes drewnoakes merged commit 33fad24 into drewnoakes:master Jul 30, 2021
drewnoakes added a commit to drewnoakes/metadata-extractor-dotnet that referenced this pull request Jul 30, 2021
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants