[Qgis-user] KML import

Walter Ludwick wludwick at mac.com
Wed Aug 17 08:43:15 PDT 2011


Is it possible to import a KML file generated by Google Earth into a QGIS project that has some CRS other than 900913 (Google Mercator EPSG: 900913) defined, and have that KML appear as a new layer correctly positioned vis-a-vis others in the project?

I have my QGIS Preferences configured to "enable "on-the-fly" reprojection by default," and i gather from what i've read here that this should do it automatically, but it is not working that way for me; the layer holding KML import appears in a different location, so that i can only visualize that layer via "zoom to extents," and then i lose sight of all the other layers. 

NB: The CRS that was used to build my project is WGS 84 (EPGS:4326), if that matters, and my  i have tried this operation in two different ways -(1) with the project CRS config left as-is, and (2) after reconfiguring CRS in my Project Properties to EPGS:900913- but i get the same result either way. Can't get the new layer to line up as it should!

Another noteworthy fact is: Merging data in the reverse direction (i.e. saving a layer out of QGIS as KML, then reading that into Google Earth), i get perfect alignment, but only if i configure CRS of the layer in QGIS to "ETRS89 / Portugal TM06 EPSG:3763"  (the subject lands are in Portugal, in fact), and then configure output CRS (in "save as... KML" dialog) to 900913 (Google Mercator EPSG: 900913). This works like a charm (thanks to this group for helping me to make it work :) 
Considering this, i have also tried modifying the CRS config to EPSG:3763 before importing the KML, but that didn't work any better. 

So: does anyone know if this is even possible? If so, can you please explain how it was done?     /w

(PS: am running QGIS version 1.7.0 Wroclaw, and Google Earth 6.0.3.2197, on Mac OS X version 10.6.8)



More information about the Qgis-user mailing list