customizing annotationClusters in MKMapView

Hi,


i have custom annotations on a map which, when clustered, display the default red annotationCluster-icon.


Now first i am trying to change this default icon to a customImage.


Second, i want the clustering to happen later than it does by default. My mapAnnotationClusters refresh a lot when i move the map a tiny bit and it displays a lot of clusters making the map look a bit unorganised and laggy -> annotations clusterd only when they are REALLY near to each other


Do you have an idea how to accomplish this?


Thank you very much already in advance.

Replies

Hello Gustulus,
I have already changed tintColor and glyphImage. Helpful was Apple`s Sample Code TANDm from WWDC2017 No237 named "Whats new in Map Kit". You can download the sample and play around with it.
On the left side is the Project-Navigation-Window of Xcode, there you see the blue folder "Assets.xcassets".
In this folder you will found and change different colors (tintColor) for the coloring of an Annotation.
You can also change the little Images in a balloon-shaped Annotation (glyphImage).
In the code, you can search for tintColor or glyphImage and change it as you wish.
You can contact me with a mail, and I can show you the code-changings, if you want.