1

我一直在 Google 文档中搜索 GDirections Api V2 的等效对象。我找到了 DirectionsRenderer 但它没有我需要的方法,即 GDirections.Load("from:some Lat, some Lng to: some Lat, some Lng").

有人知道 Api V3 中的等效对象或方法吗?

4

1 回答 1

0

请参阅文档中的此示例: https ://google-developers.appspot.com/maps/documentation/javascript/examples/directions-simple

用您想要的坐标(或包含这些坐标的 google.maps.LatLng)替换 start 和 end。

带有航点的路线: https ://google-developers.appspot.com/maps/documentation/javascript/examples/directions-waypoints

于 2012-06-27T19:31:25.860 回答