iOS Google 地图方向 api 给出了错误的扭曲路径

iOS Google Maps direction api giving wrong distorted path

这是我用来绘制方向为 api 的路径的 (https://maps.googleapis.com/maps/api/directions/json?origin=place_id:ChIJIQBpAG2ahYAR_6128GcTUEo&destination=place_id:ChIJVVVVVYx3j4ARP-3NGldc8qQ&key=xxxxxx)。

我不明白为什么这条路如此罕见。它看起来确实像两点之间的最短路径。以及为什么没有一条而不是两条平行线。

感谢任何帮助。 谢谢

在您的请求中添加 alternatives=false

例如

(https://maps.googleapis.com/maps/api/directions/json?origin=place_id:ChIJIQBpAG2ahYAR_6128GcTUEo&destination=place_id:ChIJVVVVVYx3j4ARP-3NGldc8qQ&alternatives=false&key=xxxxxx)

它会给你一条路。