Hi,
I want to draw path from one location to other location. How to plot the path between two location.
I have coordinates(latitude,longitude) for both location.
How can i achieve this functionality?
Thanks,
Jim.
Hi,
I want to draw path from one location to other location. How to plot the path between two location.
I have coordinates(latitude,longitude) for both location.
How can i achieve this functionality?
Thanks,
Jim.
You can use google maps API to obtain path elements of the route and then draw them over the map. Also there's a MapKit extension by Kishikawa Katsumi available for download on github that provides this functionality.
- (CGPoint)convertCoordinate:(CLLocationCoordinate2D)coordinate toPointToView:(UIView *)view
, CGContextMoveToPoint
and CGContextAddLineToPoint
should get you started.