bpillon / google_maps_cluster_manager

Simple Flutter clustering library for Google Maps
https://pub.dev/packages/google_maps_cluster_manager
MIT License
119 stars 95 forks source link

create different markers icon #18

Closed mashegoindustries closed 3 years ago

mashegoindustries commented 3 years ago

I have 4 different types of markers that I need to show on the map.

I am aware that I can create different markers icon, depending on the isMultiple property,

This means that a marker can be multiple or single. (This means maximum 2 marker icons)

My question is, How can I create multiple marker icons for single clusters?

Should I rather create 4 instances of cluster managers?

Something like this policeClusterManager = _initClusterManagerPolice(); carsClusterManager = _initClusterManagerCars(); accidentClusterManager = _initClusterManagerAccident(); storeClusterManager = _initClusterManagerstore();

bpillon commented 3 years ago

Hello, You can pass an item to a ClusterItem so you are able to create different icons depending on the item the ClusterItem contains.