[gdal-dev] Conversion problem proj4 -> wkt ->proj4

Christopher Schmidt crschmidt at metacarta.com
Tue Jan 29 10:19:12 EST 2008


On Tue, Jan 29, 2008 at 08:09:16AM +0100, Oliver Eichler wrote:
> Hi,
> 
> I try to convert a proj4 string into wkt to store it into a GeoTiff. Later on 
> I need to restore the projection from the string. However the most important 
> part "+nadgrids=@null" is missing. See attached file. Anyone knows how to "do 
> it right"?

Use "+wktext" -- this tells it to store a special piece of metadata with
the actual proj4 in it:

+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0
+k=1.0 +units=m +nadgrids=@null +wktext  +no_defs

The WKT should then match this:
http://spatialreference.org/ref/user/6/prettywkt/

Regards,
-- 
Christopher Schmidt
MetaCarta


More information about the gdal-dev mailing list