Martijn van Oosterhout
kleptog at gmail.com
Wed May 7 10:24:33 BST 2008
On Wed, May 7, 2008 at 10:44 AM, Brett Henderson <brett at bretth.com> wrote:
> Actually my problem was much simpler. I was just looking for a way of
> taking a big bounding box (ie. a box around Australia) and splitting it
> into smaller tiles (let's say 10km square for arguments sake). The
> problem you run into is that ways and polygons cross tiles so they have
> to be split. The problem in the current model is that you don't know if
> a way is a simple line to be cut in half at the tile borders and a
> synthetic node inserted or a polygon where the rules for splitting it
> are more complicated. If we had a polygon type this problem goes away
> and I wouldn't have to look at tags at all, I'd just have to copy tags
> across split ways and polygons.
The logic already exists in one place: osm2pgsql. One way to do it
would be to use osm2pgsql to push it into shapefiles, from there they
can be easily tiled.
Now, I won't say the logic in osm2pgsql is foolproof right now. I do
wish people/editors would add an area=yes tag to the non-obvious
cases. Just because the API doesn't understand the concept, there's no
reason why editors like JOSM and potlatch can't make the distinction.
Have a nice day,
Martijn van Oosterhout <kleptog at gmail.com> http://svana.org/kleptog/
More information about the dev