假設我有一個GPS單元加載到數據庫中的位置列表。現在我想Google地圖顯示這些位置,這就像這樣開箱即可使用谷歌地圖api v3多段線對齊到最近的街道
new google.maps.LatLng(57.046085209585726, 9.917740747332573),
new google.maps.LatLng(57.04606626648456, 9.918211475014687),
new google.maps.LatLng(57.04656251706183, 9.917992874979973),
new google.maps.LatLng(57.04649009741843, 9.918401995673776),
new google.maps.LatLng(57.04628427978605, 9.91844767704606),
new google.maps.LatLng(57.04613022040576, 9.91837676614523),
new google.maps.LatLng(57.045781994238496, 9.918353715911508),
new google.maps.LatLng(57.045685979537666, 9.918150706216693),
new google.maps.LatLng(57.0457204291597, 9.917718200013041),
new google.maps.LatLng()
問題是。由於多邊形線路切斷了角落,並且由於不太正確的GPS設備,它會看起來像您穿過建築物和游泳池到達街道的另一側。 有沒有什麼辦法可以使我的數據庫中的定位數據捕捉到最近的街道?
謝謝大家 喬納斯