How to make a marker adjust its size based on zoom level Google Maps v2

本小妞迷上赌 提交于 2019-12-11 07:08:06

问题


I'm trying to follow the behavior of Google Maps, wherein the markers of certain landmark appear small in a lower zoom level, but bigger on a higher level. I was already able to make a custom marker disappear by zoom level, now I want to make its size adjust relevant to the zoom level. Any help would be appreciated. Thanks. Android Newbie here.


回答1:


In onCameraChange instead of calling setVisible, call setIcon with different BitmapDescriptor depending on zoom level.



来源:https://stackoverflow.com/questions/19156082/how-to-make-a-marker-adjust-its-size-based-on-zoom-level-google-maps-v2

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