-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Coordinates in encoded polyline are scaled by factor 10 #713
Comments
We are providing coordinates with higher precision than google. The easiest fix is to change the 5 in this and the following line to a 6, i.e. divide by |
Thanks for the quick reply. |
Done, now it says "The geometry of the route is transferred in encoded form. See here for a definition of the format. The route geometry is compressed with a precision of six digits. See here for a proper JavaScript implementation." |
Here is another implementation. I fixed changing the division for 1e6 as you said. Thank you very much! |
Marble uses the json API to retrieve OSRM routes. This used to work fine, but lately the polyline decoding returns coordinates where each lat, lon pair is scaled by factor 10 each. The polyline decoding in Marble hasn't changed since I wrote it and it decodes strings from https://developers.google.com/maps/documentation/utilities/polylineutility fine. Am I missing some additional parameter that needs to be evaluated? Or is it some bug in OSRM maybe? I'd rather not go for dividing by ten in Marble without understanding what's going on.
There's a KDE bug report for it as well over at https://bugs.kde.org/show_bug.cgi?id=323772
The text was updated successfully, but these errors were encountered: