[gdal-dev] ogr2ogr: problems converting from shapefile to kml

Even Rouault even.rouault at mines-paris.org
Wed Apr 6 19:02:25 EDT 2011


Le jeudi 07 avril 2011 00:39:59, Vishal Mehta a écrit :
> Hi all,
> 
> I'm having some trouble with a simple conversion from shapefile to kml.
> Description
> 1. I need to have a points file in kml that is is EPSG 3857 (the mercator
> that Google uses)

I'm afraid that you are loosing your time. KML coordinates must be expressed 
in EPSG:4326 per the spec.

See http://code.google.com/intl/fr/apis/kml/documentation/kmlreference.html 
and specifically :

"""<Location>
    Specifies the exact coordinates of the Model's origin in latitude, 
longitude, and altitude. Latitude and longitude measurements are standard lat-
lon projection with WGS84 datum. """

This is also reminded in the OGR KML doc : see 
http://gdal.org/ogr/drv_kml.html


More information about the gdal-dev mailing list