[OSM-dev] shp2multipolygon

André Riedel riedel.andre at gmail.com
Thu Jun 30 14:28:48 BST 2011


There is a python program programm named ogr2osm

http://wiki.openstreetmap.org/wiki/Ogr2osm

It does exactly what you want.

Ciao André

2011/6/30 Anthony <osm at inbox.org>:
> Does anyone have code to do shapefile to multipolygon (in
> .osm/.pbf/.o5c format)?  What I want is to take a shapefile with
> overlapping boundaries (e.g.
> http://wiki.sharedmap.org/wiki/File:Qgis.png) and convert it into a
> bunch of multipolygons with shared ways.
>
> I used to have code to do this:
> http://wiki.openstreetmap.org/wiki/User:%E2%A0%A0%E2%A0%81%E2%A0%9D%E2%A0%9E%E2%A0%93%E2%A0%95%E2%A0%9D%E2%A0%BD/SQL
> and http://wiki.openstreetmap.org/wiki/User:%E2%A0%A0%E2%A0%81%E2%A0%9D%E2%A0%9E%E2%A0%93%E2%A0%95%E2%A0%9D%E2%A0%BD/Perl
>
> But I didn't document it well enough and I forget how it works :).
> And John is having a problem with it in that it only seems to work
> when interior ways are exactly two nodes.
>
> My understanding is that, as of about a year ago, none of the shp2osm
> programs support multipolygons.  Hopefully this has changed.
>
> _______________________________________________
> dev mailing list
> dev at openstreetmap.org
> http://lists.openstreetmap.org/listinfo/dev
>



More information about the dev mailing list