I looked on the Internet to try and find the best way to draw a line showing the route the user was traveling. I think I need to use MKOverlayView, and I think I need to collect a selection of data points for the graph (will these be GPS coordinates?). The question I have is based on how I will draw a line and continue to add it as user location updates?
I also want to clear the line when the user clicks a button. How would I implement this (don’t click a button, just a code to clear the line from the map view)?
Thanks in advance!
source
share