Opened 10 years ago
Closed 10 years ago
#64 closed defect (fixed)
listgeo: output format issue
Reported by: | Ahlzen | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | libgeotiff | Version: | 1.3.0 |
Keywords: | Cc: |
Description
In some cases, listgeo doesn't provide adequate spacing after floating point numbers. While the result usually human readable, this causes an incorrect projection when using listgeo/geotifcp for preserving projection data when modifying GeoTIFFs.
Here's a listgeo output example. Note the lack of space between the two numbers in the ModelTiepointTag.
Geotiff_Information: Version: 1 Key_Revision: 1.0 Tagged_Information: ModelTiepointTag (2,3): 0 0 0 -8187088.029025615298217.58570981 0 ModelPixelScaleTag (1,3): 13.462450292769 13.462450292769 0 End_Of_Tags. Keyed_Information: GTModelTypeGeoKey (Short,1): ModelTypeProjected GTRasterTypeGeoKey (Short,1): RasterPixelIsArea GTCitationGeoKey (Ascii,28): "Google Maps Global Mercator" GeographicTypeGeoKey (Short,1): GCS_WGS_84 GeogCitationGeoKey (Ascii,7): "WGS 84" GeogAngularUnitsGeoKey (Short,1): Angular_Degree GeogSemiMajorAxisGeoKey (Double,1): 6378137 GeogInvFlatteningGeoKey (Double,1): 298.257223563 ProjectedCSTypeGeoKey (Short,1): User-Defined ProjectionGeoKey (Short,1): User-Defined ProjCoordTransGeoKey (Short,1): CT_Mercator ProjLinearUnitsGeoKey (Short,1): Linear_Meter ProjNatOriginLongGeoKey (Double,1): 0 ProjNatOriginLatGeoKey (Double,1): 0 ProjFalseEastingGeoKey (Double,1): 0 ProjFalseNorthingGeoKey (Double,1): 0 ProjScaleAtNatOriginGeoKey (Double,1): 1 End_Of_Keys. End_Of_Geotiff. Projection Method: CT_Mercator ProjNatOriginLatGeoKey: 0.000000 ( 0d 0' 0.00"N) ProjNatOriginLongGeoKey: 0.000000 ( 0d 0' 0.00"E) ProjScaleAtNatOriginGeoKey: 1.000000 ProjFalseEastingGeoKey: 0.000000 m ProjFalseNorthingGeoKey: 0.000000 m GCS: 4326/WGS 84 Datum: 6326/World Geodetic System 1984 Ellipsoid: 7030/WGS 84 (6378137.00,6356752.31) Prime Meridian: 8901/Greenwich (0.000000/ 0d 0' 0.00"E) Projection Linear Units: 9001/metre (1.000000m) Corner Coordinates: Upper Left (-8187088.029, 5298217.586) ( 73d32'45.11"W, 43d 6' 5.14"N) Lower Left (-8187088.029, 5041529.046) ( 73d32'45.11"W, 41d23'17.90"N) Upper Right (-7777910.315, 5298217.586) ( 69d52'12.57"W, 43d 6' 5.14"N) Lower Right (-7777910.315, 5041529.046) ( 69d52'12.57"W, 41d23'17.90"N) Center (-7982499.172, 5169873.316) ( 71d42'28.84"W, 42d15' 2.61"N)
Gdalinfo from the same file below, where the origin is displayed correctly:
Driver: GTiff/GeoTIFF Files: original.tif Size is 30394, 19067 Coordinate System is: PROJCS["Google Maps Global Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS 84",6378137,298.257223563, AUTHORITY["EPSG","7030"]], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0], UNIT["degree",0.0174532925199433], AUTHORITY["EPSG","4326"]], PROJECTION["Mercator_1SP"], PARAMETER["central_meridian",0], PARAMETER["scale_factor",1], PARAMETER["false_easting",0], PARAMETER["false_northing",0], UNIT["metre",1, AUTHORITY["EPSG","9001"]]] Origin = (-8187088.029025611467659,5298217.585709805600345) Pixel Size = (13.462450292769036,-13.462450292769036) Metadata: AREA_OR_POINT=Area Image Structure Metadata: INTERLEAVE=PIXEL Corner Coordinates: Upper Left (-8187088.029, 5298217.586) ( 73d32'45.11"W, 43d 6' 5.14"N) Lower Left (-8187088.029, 5041529.046) ( 73d32'45.11"W, 41d23'17.90"N) Upper Right (-7777910.315, 5298217.586) ( 69d52'12.57"W, 43d 6' 5.14"N) Lower Right (-7777910.315, 5041529.046) ( 69d52'12.57"W, 41d23'17.90"N) Center (-7982499.172, 5169873.316) ( 71d42'28.84"W, 42d15' 2.61"N) Band 1 Block=30394x1 Type=Byte, ColorInterp=Gray Mask Flags: PER_DATASET ALPHA Band 2 Block=30394x1 Type=Byte, ColorInterp=Alpha
Change History (3)
comment:1 by , 10 years ago
comment:2 by , 10 years ago
Unfortunately I don't have a small example file. However, I built 1.4.0 and the problem does indeed seem to be fixed there, so you can probably safely close it.
comment:3 by , 10 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
I thought I had fixed this a while ago. Do you have a smallish geotiff file that demonstrates this still happening?