Very long routes are incorrectly decoded and drawn

Topics: Bugs
Jun 28, 2013 at 9:01 AM
I've noticed that very long routes are incorrectly decoded when using GoogleMap provider so one are instructed to drive over mountains and oceans :)

Got it working by removing following replace in GoogleMapProvider.cs
string encoded = encodedPoints.Replace("\\\\", "\\");
And change all encoded to encodedPoints in that function.
Coordinator
Jun 28, 2013 at 9:21 AM
what do you mean 'Got it working' ?
Jun 28, 2013 at 9:42 AM
The route follows the road and not over oceans and mountains. The distance maybe is not the actual trigger of this problem.

Also, I don't understand why the replace is there in the first place. Tried to look at the polyline algorithm documentation but no mention of it.
Coordinator
Jun 28, 2013 at 9:46 AM
there was some issue, i don't remember either
Coordinator
Jun 28, 2013 at 9:54 AM
"Note that the backslash is interpreted as an escape character within string literals. Any output of this utility should convert backslash characters to double-backslashes within string literals."

i guess thats why, https://developers.google.com/maps/documentation/utilities/polylinealgorithm?hl=lt
Jun 28, 2013 at 9:57 AM
Maybe the conversion already has taken place before. Will load up wireshark and check that.