Opened 14 years ago
Closed 14 years ago
#36 closed defect (fixed)
PrintTag (geo_print.c) could produce unreadable results
Reported by: | rnicz | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | libgeotiff | Version: | |
Keywords: | Cc: |
Description (last modified by )
In some cases listgeo could produce unreadeble ModelPixelScaleTag values.
Format code for sprint (FMT_DOUBLE - "%-17.15g") could use all 17 characters and PrintTag (geo_print.c) procedure don't care about spaces between fields. In result you can get following listgeo output:
ModelPixelScaleTag (1,3): 0.5002263635690950.5002263635690950
instead of
ModelPixelScaleTag (1,3): 0.500226363569095 0.500226363569095 0
Unfortunatelly bad formatting is not detected by geotifcp.
--
Best regards
RNicz
Attachments (1)
Change History (5)
comment:1 by , 14 years ago
Description: | modified (diff) |
---|
comment:2 by , 14 years ago
At the moment I'm not able to attach tiff image, but I've send #36-test.meta file which could be used to initialize geotiff with geotifcp, and resulting image file could be used to reproduce error. As I think, it is enought to use ModelPixelScaleTag values I cited in my post to reproduce this error. If it fails, I would send image file tomorrow.
comment:3 by , 14 years ago
Status: | new → assigned |
---|
I have confirmed the problem using the steps:
geotifcp -g #36-test.meta utm.tif out.tif listgeo out.tif > 2.meta geotifcp -g 2.meta utm.tif out2.tif listgeo out2.tif > 3.meta
the 2.meta file has:
ModelPixelScaleTag (1,3): 0.5002263635690950.5002263635690950
and 3.meta has:
ModelPixelScaleTag (1,3): 0.5002263635690950 0
comment:4 by , 14 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
I have modified geo_print.c to put a space between numbers to avoid this problem (r1987).
Could you supply a small file presenting this problem?
I have *not* encountered this with the timepoints when I thought I would in the past.