How to get directions on the iPhone or iPad

浪尽此生 提交于 2019-12-06 09:03:43

问题


Hi I would like to in my application display something like: you're destination is 400 ft north west.

I currently use the getDistanceFrom method but that only gives me the feet between 2 locations.

Thanks for your help.


回答1:


You probably should simply use Latitude Longitude equations to calculate the bearing and then set certain ranges of bearings to be SW,S,SE, etc.

http://www.movable-type.co.uk/scripts/latlong.html



来源:https://stackoverflow.com/questions/2630789/how-to-get-directions-on-the-iphone-or-ipad

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!