[gdal-dev] Fwd: OSRExportToProj4 losing datum

Oliver Soong osoong+gdal at gmail.com
Fri Nov 2 22:31:52 PDT 2012


The attached raster is in Albers_Conic_Equal_Area on
North_American_Datum_1983.  This is correctly indicated by the WKT.
The PROJ.4 string has no such datum information.  This causes problems
with rgdal in R, which uses the PROJ.4 string and never receives the
datum information.

This seems to be limited to Albers_Conic_Equal_Area and
North_American_Datum_1983, although our testing has been limited.

> gdalinfo --version
GDAL 1.9.2, released 2012/10/08
> gdalinfo -proj4 test.tif
[...]
Coordinate System is:
PROJCS["unnamed",
    GEOGCS["NAD83",
        DATUM["North_American_Datum_1983",
            SPHEROID["GRS 1980",6378137,298.2572221010002,
                AUTHORITY["EPSG","7019"]],
            TOWGS84[0,0,0,0,0,0,0],
            AUTHORITY["EPSG","6269"]],
        PRIMEM["Greenwich",0],
        UNIT["degree",0.0174532925199433],
        AUTHORITY["EPSG","4269"]],
    PROJECTION["Albers_Conic_Equal_Area"],
    PARAMETER["standard_parallel_1",29.5],
    PARAMETER["standard_parallel_2",45.5],
    PARAMETER["latitude_of_center",23],
    PARAMETER["longitude_of_center",-96],
    PARAMETER["false_easting",0],
    PARAMETER["false_northing",0],
    UNIT["metre",1,
        AUTHORITY["EPSG","9001"]]]
PROJ.4 string is:
'+proj=aea +lat_1=29.5 +lat_2=45.5 +lat_0=23 +lon_0=-96 +x_0=0 +y_0=0
+ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs '
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.tif
Type: image/tiff
Size: 545 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20121102/fa702127/attachment.tif>


More information about the gdal-dev mailing list