Reputation: 84
I'm trying to find a way to use Google Map Directions to show the directions to point A and point B without launching it as an Intent which opens the map on either Google Navigator or on your phone web browser.
Is there a way to have Google Directions on a MapView alone?
Upvotes: 4
Views: 2079
Reputation: 2691
Yes, there is a way. However, please keep in mind that if you wish to show directions on a Map View you will have to do do a lot of drawing of lines using a canvas, not to forget that you will still be making a call to the Google Directions API to get a JSON response which you will then have to decode.
For decoding that JSON response please refer to this excellent answer to another question: https://stackoverflow.com/a/6708458/1512836.
Upvotes: 1