[gdal-dev] OSM to KML Error
Even Rouault
even.rouault at mines-paris.org
Wed Jul 3 04:38:41 PDT 2013
Le mercredi 03 juillet 2013 13:20:10, Josua S a écrit :
> Hello
>
> I exported an OSM file from openstreetmap.org and tried to convert it to
> KML with GDAL/OGR 1.10.0. However the conversion does not succeed and I
> get a lot of these errors: "ERROR 6: Interleaved feature adding to
> different layers is not supported". Is this a known problem and is there a
> solution to prevent this error? Thank you very much.
Josua,
When converting OSM files with ogr2ogr, the features are read in an interleaved
way. For example, you can get X features from layer lines, then Y features
from layer multipolygons, then Z features from layer lines again, etc...
The writing part of the KML driver doesn't support that back-and-forth between
layers, hence this error.
A workaround is to convert to an intermediary format such as shapefile,
PostGIS, sqlite/spatialite, gml, etc... that support writing features in
layers in an interleaved way. Then you can convert to KML.
Best regards,
Even
--
Geospatial professional services
http://even.rouault.free.fr/services.html
More information about the gdal-dev
mailing list