Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android || Get Current Google Maps Route Information

Imagine a scenario where a user selects a route in the Google Maps app. They then begin following that route.

Is there a Google Maps API functionality that would allow you to get the current route information? e.g. Route Start Point, Route Finish Point, ETA, etc?

like image 440
JoeGlow Avatar asked Oct 22 '22 05:10

JoeGlow


1 Answers

Short Answer: No.

Long Answer:

There isn't an official "API" per se, but there are ways to do it. Here is a Google code project, and here is a supposedly working example but the English is hard to understand.

You could always use their web API as opposed to the Android/Java API, it's known to have better flexibility when it comes to traffic, driving directions, and other features. The downside of this is that you'd have to embed it into a WebView or similar web interface.

Also, there are places to generate driving directions into KML files. Here is a great blogpost series about getting directions from OpenStreetMap, and here is the official OpenStreetMap wiki. That should be enough to get you started; you can also find more sites on Google than I could possibly link here.

Good luck!

like image 125
crocboy Avatar answered Oct 29 '22 19:10

crocboy