Google Adds Marker Clustering to Maps SDK for iOS

Google recently announced the addition of marker clustering to its Google Maps SDK for iOS Utility Library. Marker clustering allows users to place numerous markers on a map without rendering the map unreadable. As zoom levels adjust for a particular map, markers aggregate (during zoom out) and split out (during zoom in) to keep maps clean and easy to understand. Developers have consistently requested this feature for the iOS SDK.

To enable marker clustering, developers need follow a basic, four-step process:
  1. Add 'Google-Maps-iOS-Utils' to the Podfile
  2. Instantiate the GMUClusterManager
  3. Implement the GMUClusterItem protocol for marker objects
  4. Add marker objects to the cluster manager
Google provides the default algorithm, renderer and icon generator to support implementations. Accordingly, the feature is ready to go out of the box. However, developers can fully customize each aspect to suit the needs of their Integration or app. Further, developers can provide their own versions of certain protocols (i.e. GMUCustomerAlgorithm, GMUClusterRenderer, GMUClusterIconGenerator). 

For those looking for more information, Google has provided the complete docs and some demos. Marker clustering is also available for Android and JavaScript. Google has provided a setup guide and some best practices for those new to the Utility Library


Be sure to read the next Mapping article: Google Pulls Places API for iOS from Maps SDK