[osmosis-dev] [RFE] Add bounding shape to OSM dumps

Frederik Ramm frederik at remote.org
Thu Jan 21 08:14:49 GMT 2010


Hi,

Apollinaris Schoell wrote:
> osmosis supports 2 options to keep ways and relations intact. but geofabrik extracts don't use it as far as I know. 
> completeWays
> completeRelations

That is correct: These options exist, and are not used, because if we'd 
use them, the nightly build would take something like three days instead 
of six hours. Osmosis works very well in streaming mode and these 
options make it impossible to stream - Osmosis needs to create a 
temporary copy of the full dataset and is rather inefficient at it.

We typically do something like

osmosis --rx file.osm --tee 20 --bp file=country1.poly --wx country1.osm 
--bp file=country2.poly --wx country2.osm...

which would causes Osmosis to make 20 temporary full copies of the data 
and write them to disk in "completeWays" mode.

We use "clipIncompleteEntities" which means that Osmosis removes 
references to those nodes outside the polygon from any ways or relations.

It would be good if Osmosis could somehow flag the clipped entities so 
that processing software could at least know that there is something 
wrong, or incomplete, with them.

Adding the actual polygon used for clipping could of course be done but 
it will not automatically enable proper filling. Assume this:

   |
+-|----+-----+
| |          |
| |          |<--- filled area
+-|----+-----+
   |
   |<-- clipping boundary

After clipping with clipIncompleteEntities, this will lead to

   |
   |    +-----+
   |    |     |
   |    |     |
   |    +-----+
   |
   |

Even if you know where the clipping boundary is, you cannot extend the 
object towards that boundary properly because you are missing the nodes 
beyond the boundary.

Bye
Frederik

-- 
Frederik Ramm  ##  eMail frederik at remote.org  ##  N49°00'09" E008°23'33"




More information about the osmosis-dev mailing list