How to get the next turning point from google map - (Android)

I am currently working on an application in which I need to find the location of the next turning point without opening any map on the phone, and then I need to save this location in a string array or Hashmap.


Example. Suppose I need to go from the city of Mumbai to the city of Delhi. When I run the application, it requests the two places source location, and destination locationin the text box and give me information about the button is pressed in the form of text, which can be as follows: -

You Are Here current location------> turn left from turning point location-----> turn right from next turning location----> when you have reached the value destination location.

Note. The user does not move to the place where he receives this information in the text from the click of a button. So I need to find the turning points (left and right turns) of the route.

I can not find a solution to this on the Internet.

So how can I do this. Can someone post a working example or give a link to the corresponding example. Thank you for your help.

+5

Source: https://habr.com/ru/post/1535916/


All Articles