Google Maps API v2 for Android: Cannot draw like deprecated Overlay

流过昼夜 提交于 2019-12-06 11:54:20

问题


I have developing an Android application, and I have moved from Google Maps for Android API v1 to v2.

With deprecated version 1 I created an Overlay for drawing some colored shapes (delimiting zones) and info text over my map, but now I have been viewing API v2 and cannot do the same.

I have trying to use Polygon property, but it doesn't fill with any colour, maybe because my shapes cannot be drawing in counterclockwise due to the pattern of them, for example a shape with 'U' pattern. Also, I don't know either how to put a text (no marker, just text) over the map.

Thanks in advance.


回答1:


still don't know how to put a text in the map

Create a Bitmap containing your text, and use a GroundOverlay, or possibly a TileOverlay.



来源:https://stackoverflow.com/questions/14269042/google-maps-api-v2-for-android-cannot-draw-like-deprecated-overlay

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!