小编Ale*_*ola的帖子

谷歌地图 Android Studio 不显示我的折线

我不知道为什么这条折线不会显示,我已经放置了谷歌地图 api 并启用了路线 api

PolylineOptions rectOptions = new PolylineOptions();

    rectOptions.add(new LatLng(24.009115, -104.699933));
    rectOptions.add(new LatLng(24.009115, -104.699933));
    rectOptions.width(5);
    rectOptions.color(Color.RED);  

   Polyline polyline = mMap.addPolyline(rectOptions);
Run Code Online (Sandbox Code Playgroud)

android google-maps google-polyline android-studio

2
推荐指数
1
解决办法
4470
查看次数