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

[PATCH] overflow with near-pole data and mercator #3452

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 3 comments
Closed

[PATCH] overflow with near-pole data and mercator #3452

openstreetmap-trac opened this issue Jul 23, 2021 · 3 comments

Comments

@openstreetmap-trac
Copy link

Reporter: Kompa
[Submitted to the original trac issue database at 3.03pm, Tuesday, 11th January 2011]

Here's a patch to (hopefully) fix "South Pole Near Africa" problem with osm2pgsql.

Demonstration of that:

What this patch does:

  1. Checks for Sphrical Mercator;
  2. Checks whether node is a lot outside tile 0/0/0. Snaps it to boundary that does not lead to overflow;
  3. Replaces proj4 calculation with direct Spherical Mercator formula, which is less strict about overflows and gave me ~5% speedup on test dataset.
@openstreetmap-trac
Copy link
Author

Author: jburgess777[at]googlemail.com
[Added to the original trac issue at 5.54pm, Sunday, 16th January 2011]

Patch applied with some minor tweaks in r25075.

@openstreetmap-trac
Copy link
Author

Author: chris66
[Added to the original trac issue at 6.35pm, Sunday, 13th February 2011]

Still South Pole data can be seen at Africa:

http://www.openstreetmap.org/?lat=-0.111&lon=0.154&zoom=10&layers=M

@openstreetmap-trac
Copy link
Author

Author: Ldp
[Added to the original trac issue at 7.06pm, Sunday, 13th February 2011]

It is fixed, in the tools.

Now, it takes time to work that out of the data and the map. It'll be gone after the next full import, which hopefully will not take that long anymore to start.

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