Search code examples
androidgoogle-mapsmaproute

How to show route between two points using google map v2


I want to show a route between two points in Google Maps V2. I am able to achieve this with V1 but Google Map V2 does not support geopoints. So what should I do?


Solution

  • You can draw Polylines for routes. Docs here:

    https://developers.google.com/maps/documentation/javascript/v2/overlays#Drawing_Polylines

    If you mean drawing an actual route that you see in Google Maps directions, read the discussion here. Basically you'll need to utilize DirectionService