-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Flickering pins on annotation updates #23
Comments
Thanks for the report @roccx , I've also noticed that flickering on iOS11 |
I'm using custom annotations views with an animation during the update and running iOS11. |
I think the issue is that every annotation is replaced by new ones as @jacogasp says. Isn't there a way to filter annotations by |
I did some debugging and I can say, that the flickering just happens when zooming not when moving the map to west/east/north/south. |
It seems like I think a solution for that problem would be to manage the annotations in a more smarter way or just delay the removal of the old annotations by 2 or 3 frames. |
@frgmt the refresh occurs to me also panning the map without zooming. |
The issue appears everytime the clusters are updated, on zoom or significant pan. As @roccx suggested, adding an annotation to |
@maxep is anyone working on the solution for this issue? Please let us know when this is fixed. In the time being is there any good alternative to fix this issue? |
I had the similar problem, and after some research, it happens that ClusterKit reloads each annotations on each pan, rotation etc. In my case, the issue was mainly visible because I have several type of annotationViews, on which I update the image depending on type of annotation to display. My workaround consists in having 1 reuseIdentifier per annotation type (including CKCluster), thus configuring my annotationViews only after instantiating them. Hope that helps ! |
I've released a new version : 0.3.0 including breaking changes answering this issue. Please check the CHANGELOG |
Just read new algorithm, seems much more efficient 🔥 |
ClusterKit is causing a flickering issue on custom annotation views using MapKit.
I have tried solving this issue by using:
- addAnnotations(...)
and- removeAnnotations(...)
,but that doesn't seam to solve the problem.
I'm calling
- updateClustersIfNeeded
in-mapView(_:, regionDidChangeAnimated:)
as described in the documentation.Tested with:
The text was updated successfully, but these errors were encountered: