tufanv Expert Licensed User Longtime User Oct 13, 2015 #1 Hello, I searhed for the tutorials but couldnt find any. Is there a way to draw the route of the gps device travelled. for example when the app started at point a , during the travel the app will draw a route ( like a line ) and when the travel finished it will stop drawing Need oyur ideas or if there is a tutorial i couldnt find please point me TY !
Hello, I searhed for the tutorials but couldnt find any. Is there a way to draw the route of the gps device travelled. for example when the app started at point a , during the travel the app will draw a route ( like a line ) and when the travel finished it will stop drawing Need oyur ideas or if there is a tutorial i couldnt find please point me TY !
Ohanian Active Member Licensed User Longtime User Oct 13, 2015 #2 Hi, Here's a quick guide : Code: Dim Direction As Polyline Direction = GoogleMap1.AddPolyline Dim llPoint As LatLng Dim points As List points.Initialize llPoint.Initialize(mpiCurrent.dLatitude, mpiCurrent.dLongitude) <<Add Your Points points.Add(llPoint) Direction.points = points Upvote 0
Hi, Here's a quick guide : Code: Dim Direction As Polyline Direction = GoogleMap1.AddPolyline Dim llPoint As LatLng Dim points As List points.Initialize llPoint.Initialize(mpiCurrent.dLatitude, mpiCurrent.dLongitude) <<Add Your Points points.Add(llPoint) Direction.points = points
tufanv Expert Licensed User Longtime User Oct 13, 2015 #3 I tried it and it works perfect ty but is there any way to change the color ( it is always black ) and is there any way to have the line on the road ( because of little gps mistakes the route driven is gets out of the way a bit ) ty Ohanian said: Hi, Here's a quick guide : Code: Dim Direction As Polyline Direction = GoogleMap1.AddPolyline Dim llPoint As LatLng Dim points As List points.Initialize llPoint.Initialize(mpiCurrent.dLatitude, mpiCurrent.dLongitude) <<Add Your Points points.Add(llPoint) Direction.points = points Click to expand... Upvote 0
I tried it and it works perfect ty but is there any way to change the color ( it is always black ) and is there any way to have the line on the road ( because of little gps mistakes the route driven is gets out of the way a bit ) ty Ohanian said: Hi, Here's a quick guide : Code: Dim Direction As Polyline Direction = GoogleMap1.AddPolyline Dim llPoint As LatLng Dim points As List points.Initialize llPoint.Initialize(mpiCurrent.dLatitude, mpiCurrent.dLongitude) <<Add Your Points points.Add(llPoint) Direction.points = points Click to expand...
eurojam Well-Known Member Licensed User Longtime User Oct 13, 2015 #4 color is no problem: Code: line = GoogleMap1.AddPolyline line.color= Colors.Red to put it on the street is more complex, one way to solve it, is using a routing service. you can try https://mapmatching.3scale.net/ for example, problem, that the routing is performed with OSM, so the route will not match the the google map in all cases. Other possibility is to use google routing service between each two gps points, which will provide the segments for your route. hope this helps stefan Upvote 0
color is no problem: Code: line = GoogleMap1.AddPolyline line.color= Colors.Red to put it on the street is more complex, one way to solve it, is using a routing service. you can try https://mapmatching.3scale.net/ for example, problem, that the routing is performed with OSM, so the route will not match the the google map in all cases. Other possibility is to use google routing service between each two gps points, which will provide the segments for your route. hope this helps stefan
tufanv Expert Licensed User Longtime User Oct 19, 2015 #5 I am using this technique to draw the way traveled. can i store this points with a mysql table to later display the route again ? or there will be so many points so that i wont be able to store them ? Is there any better way for it ? ty Upvote 0
I am using this technique to draw the way traveled. can i store this points with a mysql table to later display the route again ? or there will be so many points so that i wont be able to store them ? Is there any better way for it ? ty
eurojam Well-Known Member Licensed User Longtime User Oct 19, 2015 #6 ty, IMO storing of the points is no problem, no big data at all. you can store them either as json on the device...ask me for information if needed Upvote 0
ty, IMO storing of the points is no problem, no big data at all. you can store them either as json on the device...ask me for information if needed