[Gdal-dev] Python/OGR SHAPE creation: prj file missing
Frank Warmerdam
warmerdam at pobox.com
Wed May 31 16:49:40 EDT 2006
Markus Neteler wrote:
> Hi,
>
> I was writing a simple Python script to generate a
> SHAPE file following
> http://www.perrygeo.net/wordpress/?p=4
> (thanks, Perry!).
>
> The SHAPE related files are created, but the .prj file not.
> How to enable that?
Markus,
There is an optional "srs" argument to ogr.Datasource.CreateLayer()
that should refer to an ogr.SpatialReference object if passed. This
SRS will be "morphed" to ESRI format and exported as WKT in the .prj file.
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 | President OSGF, http://osgeo.org
More information about the Gdal-dev
mailing list