Google地图:绘制围绕随机位置的多边形

时间:2022-12-03 12:58:42

I have a set of random locations. The location set will keep changing. I would like to draw a polygon surrounding these locations.

我有一组随机位置。位置设置将不断变化。我想在这些位置周围绘制一个多边形。

Google地图:绘制围绕随机位置的多边形

Can this be done in Google Maps and how? The map will be displayed on a website only, no mobile api required.

这可以在Google地图中完成吗?地图将仅显示在网站上,不需要移动API。

1 个解决方案

#1


0  

It's called a convex hull. Here:

它被称为凸壳。这里:

http://www.geocodezip.com/v3_map-markers_convexhull.asp

http://www.geocodezip.com/v3_map-markers_convexhull.asp

I would cite the code but it belongs to @geocodezip who is the authority on google maps and runs an excellent site of examples. I suggest you check it out.

我会引用代码,但它属于@geocodezip,他是谷歌地图的权威,并运行一个很好的示例网站。我建议你看看。

#1


0  

It's called a convex hull. Here:

它被称为凸壳。这里:

http://www.geocodezip.com/v3_map-markers_convexhull.asp

http://www.geocodezip.com/v3_map-markers_convexhull.asp

I would cite the code but it belongs to @geocodezip who is the authority on google maps and runs an excellent site of examples. I suggest you check it out.

我会引用代码,但它属于@geocodezip,他是谷歌地图的权威,并运行一个很好的示例网站。我建议你看看。