Issue
I have a particular need with a mapView and i can't find any good solution.
I have a Mapview with some markers displayed on it, and it works perfectly. My need is that i want to put a kind of layer/background on the screen, in order to "mask" the map, but i always want to see the markers, and keep all the mapview functionnalities (zoom, move, etc.) Is there any solution available to do it?
I hope you understand my need.
Many thanks in advance.
Solution
Create an overlay that mask (cover) the part of the map that you want to cover. In the onDraw()
of this oevrlay just draw something that achive your mask requirements (areas, colors and opacity).
To ensure that markers are always visible, you need to add the overlay with markers after you add the overlay that mask map to the mapView.getOverlays.add()
.
Enjoy it.
Answered By - Luis
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.