[Qgis-developer] Different gdalinfo Results

M Lewis Martin.Lewis at euro.ngc.com
Fri Aug 22 01:00:32 PDT 2014


I have already raised this on the GDAL-Dev forum (a lot of help but no
conclusive answer) so sorry for cross posting but this might make more sense
here.
I use QGIS for verification of an application that uses pure GDAL (built by
myself)
I have had some problems with a particular MrSID file where 'gdalinfo' run
from QGIS gives a different (although correct result) compared to 'pure'
gdal.
Both versions when running 'gdalinfo --version' give 'GDAL 1.11.0, released
2014/04/16'
I am building GDAL using the latest MrSID DSDK 9.0.0.3864.

The results of the gdal_info are as follows, the differences highlighted in
bold:

Output from QGIS gdal info 
----------------------------------------------------------------------- 
Driver: MrSID/Multi-resolution Seamless Image Database (MrSID) 
Files: E:\Stuff\Maps\georgiaville_se.sid 
Size is 5189, 6945 
Coordinate System is: 
*PROJCS["NAD83 / Rhode Island",*
    GEOGCS["NAD83", 
        DATUM["North_American_Datum_1983", 
            SPHEROID["GRS 1980",6378137,298.2572221010002, 
                AUTHORITY["EPSG","7019"]], 
            AUTHORITY["EPSG","6269"]], 
        PRIMEM["Greenwich",0], 
        UNIT["degree",0.0174532925199433], 
        AUTHORITY["EPSG","4269"]], 
    PROJECTION["Transverse_Mercator"], 
    PARAMETER["latitude_of_origin",41.08333333333334], 
    PARAMETER["central_meridian",-71.5], 
    PARAMETER["scale_factor",0.99999375], 
*    PARAMETER["false_easting",328083.3333333333],*
    PARAMETER["false_northing",0], 
*    UNIT["US survey foot",0.3048006096012192, *
        AUTHORITY["EPSG","9003"]]]
Origin = (311060.109583333310000,311248.359216666660000) 
Pixel Size = (3.280833333333334,-3.280833333333334) 
Metadata: 
  GEOTIFF_CHAR__GTModelTypeGeoKey=ModelTypeProjected 
  GEOTIFF_CHAR__GTRasterTypeGeoKey=RasterPixelIsArea 
  GEOTIFF_CHAR__ProjectedCSTypeGeoKey=PCS_NAD83_Rhode_Island 
  GEOTIFF_CHAR__ProjLinearUnitsGeoKey=Linear_Foot_US_Survey 
  GEOTIFF_NUM__1024__GTModelTypeGeoKey=1 
  GEOTIFF_NUM__1025__GTRasterTypeGeoKey=1 
  GEOTIFF_NUM__1026__GTCitationGeoKey=IMAGINE GeoTIFF Support 
Copyright 1991 - 2001 by ERDAS, Inc. All Rights Reserved 
@(#)$RCSfile: egtf.c $ $Revision: 1.10.1.6 $ $Date: 2003/10/17 16:36:51EDT $ 
Projection Name = State Plane 
Units = feet 
GeoTIFF Units = feet 
  GEOTIFF_NUM__3072__ProjectedCSTypeGeoKey=32130 
  GEOTIFF_NUM__3073__PCSCitationGeoKey=IMAGINE GeoTIFF Support 
Copyright 1991 - 2001 by ERDAS, Inc. All Rights Reserved 
@(#)$RCSfile: egtf.c $ $Revision: 1.10.1.6 $ $Date: 2003/10/17 16:36:51EDT $ 
State Plane Zone -3800 
NAD = 83 
  GEOTIFF_NUM__3076__ProjLinearUnitsGeoKey=9003 
  IMAGE__COMPRESSION_BLOCK_SIZE=512 
  IMAGE__COMPRESSION_GAMMA=2.000000 
  IMAGE__COMPRESSION_NLEV=7 
  IMAGE__COMPRESSION_VERSION=2,0,0 
  IMAGE__COMPRESSION_WEIGHT=2.000000 
  IMAGE__CREATION_DATE=Mon Feb 07 13:53:36 2005 

  IMAGE__INPUT_FILE_SIZE=108169367.000000 
  IMAGE__INPUT_FORMAT=GeoTIFF 
  IMAGE__INPUT_NAME=E:\Aerials\USDA\TIFS\4107104_se.tif 
  IMAGE__TARGET_COMPRESSION_RATIO=25.000000 
  VERSION=MG2 
Image Structure Metadata: 
  INTERLEAVE=PIXEL 
Corner Coordinates: 
*Upper Left  (  311060.110,  311248.359) ( 71d33'45.24"W, 41d56'15.01"N) 
Lower Left  (  311060.110,  288462.972) ( 71d33'45.02"W, 41d52'29.91"N) 
Upper Right (  328084.354,  311248.359) ( 71d29'59.99"W, 41d56'15.07"N) 
Lower Right (  328084.354,  288462.972) ( 71d29'59.99"W, 41d52'29.97"N) 
Center      (  319572.232,  299855.665) ( 71d31'52.56"W, 41d54'22.51"N)*
Band 1 Block=1024x128 Type=Byte, ColorInterp=Red 
  Minimum=23.000, Maximum=253.000, Mean=76.340, StdDev=27.247 
  Overviews: 2595x3473, 1298x1737, 649x869, 325x435, 163x218, 82x109, 41x55 
Band 2 Block=1024x128 Type=Byte, ColorInterp=Green 
  Minimum=36.000, Maximum=254.000, Mean=92.388, StdDev=23.622 
  Overviews: 2595x3473, 1298x1737, 649x869, 325x435, 163x218, 82x109, 41x55 
Band 3 Block=1024x128 Type=Byte, ColorInterp=Blue 
  Minimum=46.000, Maximum=254.000, Mean=82.477, StdDev=21.573 
  Overviews: 2595x3473, 1298x1737, 649x869, 325x435, 163x218, 82x109, 41x55 




Output from 'pure gdal' gdalinfo 
------------------------------------------------------------------------ 
Driver: MrSID/Multi-resolution Seamless Image Database (MrSID) 
Files: C:\Stuff\MrSid\Georgiaville_SE\georgiaville_se.sid 
Size is 5189, 6945 
Coordinate System is: 
*PROJCS["State Plane",*
    GEOGCS["NAD83", 
        DATUM["North_American_Datum_1983", 
            SPHEROID["GRS 1980",6378137,298.2572221010002, 
                AUTHORITY["EPSG","7019"]], 
            AUTHORITY["EPSG","6269"]], 
        PRIMEM["Greenwich",0], 
        UNIT["degree",0.0174532925199433], 
        AUTHORITY["EPSG","4269"]], 
    PROJECTION["Transverse_Mercator"], 
    PARAMETER["latitude_of_origin",41.08333333333334], 
    PARAMETER["central_meridian",-71.5], 
    PARAMETER["scale_factor",0.99999375], 
*    PARAMETER["false_easting",1076386.736111111],*
    PARAMETER["false_northing",0], 
*    UNIT["feet",0.3048006096012192]]*
Origin = (311060.109583333310000,311248.359216666660000) 
Pixel Size = (3.280833333333334,-3.280833333333334) 
Metadata: 
  GEOTIFF_CHAR__GTModelTypeGeoKey=ModelTypeProjected 
  GEOTIFF_CHAR__GTRasterTypeGeoKey=RasterPixelIsArea 
  GEOTIFF_CHAR__ProjectedCSTypeGeoKey=PCS_NAD83_Rhode_Island 
  GEOTIFF_CHAR__ProjLinearUnitsGeoKey=Linear_Foot_US_Survey 
  GEOTIFF_NUM__1024__GTModelTypeGeoKey=1 
  GEOTIFF_NUM__1025__GTRasterTypeGeoKey=1 
  GEOTIFF_NUM__1026__GTCitationGeoKey=IMAGINE GeoTIFF Support 
Copyright 1991 - 2001 by ERDAS, Inc. All Rights Reserved 
@(#)$RCSfile: egtf.c $ $Revision: 1.10.1.6 $ $Date: 2003/10/17 16:36:51EDT $ 
Projection Name = State Plane 
Units = feet 
GeoTIFF Units = feet 
  GEOTIFF_NUM__3072__ProjectedCSTypeGeoKey=32130 
  GEOTIFF_NUM__3073__PCSCitationGeoKey=IMAGINE GeoTIFF Support 
Copyright 1991 - 2001 by ERDAS, Inc. All Rights Reserved 
@(#)$RCSfile: egtf.c $ $Revision: 1.10.1.6 $ $Date: 2003/10/17 16:36:51EDT $ 
State Plane Zone -3800 
NAD = 83 
  GEOTIFF_NUM__3076__ProjLinearUnitsGeoKey=9003 
  IMAGE__COMPRESSION_BLOCK_SIZE=512 
  IMAGE__COMPRESSION_GAMMA=2.000000 
  IMAGE__COMPRESSION_NLEV=7 
  IMAGE__COMPRESSION_VERSION=2,0,0 
  IMAGE__COMPRESSION_WEIGHT=2.000000 
  IMAGE__CREATION_DATE=Mon Feb 07 13:53:36 2005 

  IMAGE__INPUT_FILE_SIZE=108169367.000000 
  IMAGE__INPUT_FORMAT=GeoTIFF 
  IMAGE__INPUT_NAME=E:\Aerials\USDA\TIFS\4107104_se.tif 
  IMAGE__TARGET_COMPRESSION_RATIO=25.000000 
  VERSION=MG2 
Image Structure Metadata: 
  INTERLEAVE=PIXEL 
Corner Coordinates: 
*Upper Left  (  311060.110,  311248.359) ( 74d18'40.33"W, 41d54'11.14"N) 
Lower Left  (  311060.110,  288462.972) ( 74d18'30.47"W, 41d50'26.31"N) 
Upper Right (  328084.354,  311248.359) ( 74d14'55.46"W, 41d54'16.59"N) 
Lower Right (  328084.354,  288462.972) ( 74d14'45.82"W, 41d50'31.75"N) 
Center      (  319572.232,  299855.665) ( 74d16'43.02"W, 41d52'21.46"N)*
Band 1 Block=1024x128 Type=Byte, ColorInterp=Red 
  Minimum=23.000, Maximum=253.000, Mean=76.340, StdDev=27.247 
  Overviews: 2595x3473, 1298x1737, 649x869, 325x435, 163x218, 82x109, 41x55 
Band 2 Block=1024x128 Type=Byte, ColorInterp=Green 
  Minimum=36.000, Maximum=254.000, Mean=92.388, StdDev=23.622 
  Overviews: 2595x3473, 1298x1737, 649x869, 325x435, 163x218, 82x109, 41x55 
Band 3 Block=1024x128 Type=Byte, ColorInterp=Blue 
  Minimum=46.000, Maximum=254.000, Mean=82.477, StdDev=21.573 
  Overviews: 2595x3473, 1298x1737, 649x869, 325x435, 163x218, 82x109, 41x55 

The problem appears to be in the 'false_easting'.

What I would like to know is, what QGIS does differently? 
The answer from GDAL-Dev was that there was a bug in gdal but how can this
be if QGIS reports a different answer using the same gdal version?
What can I do to make my gdal do the same as the gdal built into QGIS? Is it
a tweaked data file?
This is causing me major issues as I need to be able to display these MrSID
files in the application that we have and at the moment they are about 145
miles out!

Hope someone can help.

Thanks

Martin



--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Different-gdalinfo-Results-tp5157771.html
Sent from the Quantum GIS - Developer mailing list archive at Nabble.com.


More information about the Qgis-developer mailing list