[OSM-dev] Polygon relationificator
Iván Sánchez Ortega
ivan at sanchezortega.es
Mon Sep 14 12:29:13 BST 2009
During the imports support group conference call, the question of import tools
I can't quite recall everyone's point of view, but I think that the general
idea was "the more tools, the better".
I'm all for an unix-like approach: lots of small specialised tools, that work
together in order to do an import. Right now we got conversors, filters,
uploaders and whatnot.
But one thing I'm missing is a "polygon relationificator". Let me explain.
Let's suppose I've got a shapefile/GML/spatialite file full of polygons; and
such polygons do not overlap each other, and are adjacent to each other to
cover a large area. Think land use and administrative areas.
And, as defined in http://wiki.osm.org/wiki/Multipolygon , we can have
multipolygons with several outer ways - which will be joined together when
exporting to another format (e.g. osm2pgsql).
You can see where this goes. If the input polygons are non-overlapping and
adjacent, I could redraw the edges of the polygons as graph edges, put a
graph node whenever three (or more) polygons touch each other, and then apply
some graph theory to convert every polygon to a set of graph edges ( =
relation of ways = multipolygon with several outer ways )
IMHO, this would be good not only for data imports, but also for integrity
checks (detect overlaps) and cleanup, given OSM input and OSM output.
Is such a tool available? If not, who has interest in making such tool?
Iván Sánchez Ortega <ivan at sanchezortega.es>
La tradición es la personalidad de los imbéciles.- Maurice Ravel.
More information about the dev