简体   繁体   English

如何获取在两个标记之间绘制的折线的坐标列表(Lat,Long)

[英]How to get the list of coordinates (Lat, Long) of a poly-line drawn between drawn between two markers

实际上,我需要一个绘制线条的坐标列表,请在图片中详细提及

When drawing a PloyLine save it in a global variable , If there are multiple PolyLines save them in a list .在绘制PloyLine在一个全局变量保存,如果有多个PolyLines它们保存在一个列表中。 Use method polyline.getPoints() on PolyLine variable it will give you the List<LatLng>PolyLine变量上使用方法polyline.getPoints()它会给你List<LatLng>

Edit: If you want multiple points just find the center point between two points check midpoint between two latitude and longitude编辑:如果你想要多个点,只需找到两点之间的中心点检查两个纬度和经度之间的中点

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM