I'm trying to implement something like in Google Maps
samples and their CircleDemoActivity
:
Android Samples
The problem is that, the circle is disappearing and appearing, and I recorded that problem
Google Maps Sample problem
In my opinion that part should work:
if (marker.equals(radiusMarker)) {
radius = toRadiusMeters(centerMarker.getPosition(), radiusMarker.getPosition());
circle.setRadius(radius);
return true;
}
and the problem is with setRadius
method, but maybe is some workaround.
Question
How to fix that?
Few months ago I had to implement an animation of a circle growing and shrinking to under a marker to inform our user that the marker location was not precisely known.
In a first implementation I used a circle and had the same issue. I ended up using a GroundOverlay with a circle image and it does not blink. It may just require more maths to get the correct radius.
I hope it could help :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With