[Gdal-dev] processing SRTM-3?

Frank Warmerdam warmerdam at pobox.com
Thu Jul 29 15:15:10 EDT 2004


jluis at ualg.pt wrote:
> Frank
> I'm afraid that the cases I'm testing cover both situations.
> I have .prj file for the file N37W008.hgt, which has
> GEOGCS["wgs84",
>     DATUM["WGS_1984",
>         SPHEROID["wgs84",6378137,298.257223563],
>         TOWGS84[0.000000,0.000000,0.000000]],
>     PRIMEM["Greenwich",0],
>     UNIT["degree",0.0174532925199433]]
> 
> However, for an other srtm file I don't have the .prj
> In both cases I don't get the GEOGCS[] stuff

Joaquim,

Well, I am not sure why this behaviour would have changed in recent
memory.  However, I see that it was currently illegal to have multi-line
WKT definitions in ESRI .prj files the way the reading code was working.
ESRI always emits stuff as a single long line.

However, I have updated the reading code in CVS (gdal/ogr/ogr_srs_esri.cpp)
so that multiline format (as you have used) will also work.

Try updating from CVS again, or just merge your definition all into one
long line.

> BTW, I was on the way to search what a .prj file must contain.
> Can you point me to a place where I can study it?

There are two general formats.  Old Arc/Info 7.x .prj files have a line for
each parameter in a particular format.  The ArcGIS 8.x and later use an
ESRI varient of OGC Well Known Text in their .prj files.  Some massaging is
done to this internally to bring  it into the naming scheme used by GDAL/OGR.

Best regards,

---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent




More information about the Gdal-dev mailing list