Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

Map download does not return all relevant ways #1735

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 1 comment
Closed

Map download does not return all relevant ways #1735

openstreetmap-trac opened this issue Jul 23, 2021 · 1 comment

Comments

@openstreetmap-trac
Copy link

Reporter: stuuf
[Submitted to the original trac issue database at 5.18pm, Wednesday, 22nd April 2009]

This is a rather large problem with some annoying rendering implications that I noticed many months ago, and since it's apparently been overlooked in the recent database/api upgrade I figured I'd report it here.

When downloading map data within a bounding box, the algorithm used seems to be something like this:

  1. select all nodes within the box
  2. select all ways that contain nodes from 1
  3. select any additional nodes contained by ways in 2

If you know enough about geometry, you should realize that this does NOT include the complete definition of a line segment intersecting a bounding box. Consider this situation:

  +----------+
* |          |
 \|          |
  X          |
  |\         |
  | \        |
  +--X-------+
      \
       \
        * 

The line segment obviously crosses through the box, but since neither of its endpoints (*) fall within the box the API won't select it.

Mapnik seems to use PostGIS's geometry operators to search so I don't think it's affected by this, but Osmarender will often miss ways that cross through tiles but don't have any nodes in that tile. Ways like US county lines, which usually have very long straight segments that cover many tiles, only get rendered on the corners, with spaces in between.

I've confirmed this problem still exists in api 0.6 using JOSM

@openstreetmap-trac
Copy link
Author

Author: iandees
[Added to the original trac issue at 6.33pm, Monday, 9th September 2013]

Cleaning old tickets.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant