Aspose.GIS Render - Clustering Markers

Hello,

I was wondering if there is any feature and/or sample code to demonstrate clustering of markers, allowing grouping of these items.

This feature is extremely useful when dealing with large collections of marker points located close to each other by possibly putting one marker with a total count of all the grouped markers. The grouping rule could be specified by a “distance variable” to control how and when items are grouped.

Thanks

Hello, @yemoku!

Thank you for your interest in the Aspose.GIS product.

We’ve created a ticket GISNET-522 for implementation of this functionality. And we will update you here as soon as additional information is available.

Best regards.

Hello, @yemoku

Aspose.GIS 20.09.0 has been published. This release includes the implementation for GISNET-522. Please, take a look at this Example

Best regards.

Dear Evgeniy,

Apologies for the long delay in response to this thread.

Thanks for the link to the sample which demonstrated the clustered grouping of markers by increasing the marker size based on the number of “itemsInCluster”.

  1. Have you also considered a code sample depicting what seems to be the “industry standard” approach where the total of items in the cluster is displayed on the marker instead? I have attached a sample image as an illustration of this point.

  2. Have you also considered implementing parameters for the clustering so that it is possible to alter how the clustering groups items? For example it would be good to cluster on a distance parameter where the items grouped are based on miles/kilometer radius. This might be useful based on the zoom level one is rendering on a map.

ThanksCluster Image.jpg (110.4 KB)

Hi, @yemoku

I have added the ‘Draw Total Of Items’ example. First, we create an image with a drawn number for the cluster. Secondly, we use RasterImageMarker which renders our image (bitmap). As result, we create a complex symbolizer to join a background circle and the drawn digit.

Alos I’ve created a ticket GISNET-1224 for implementation of TextMarker symbolizer. This simbolizer will simplify text rendering for markers.

Please see the MarkerCluster constructor to specify the distance that collects the nearest points. It is possible to use Measurement.MetersOnEarth for miles and kilometers

Best Regards.

Evgeniy,

Ok this is great. Looking forward to the changes on the TextMarker symbolizer for text rendering.

Thanks