Page 1 of 1

Delay Cluster effect on WpfMap

Posted: Thu Feb 22, 2018 6:24 pm
by PaulBuechs
Hi,

We are facing some issues during clustering our objects on WpfMap. On DemoCenter Code we find following line:
var clusterer = new TileBasedPointClusterer<Post>(MapView.LogicalSize, 0, 19);
In the moment the cluster effect starts rather early and we would like to have it in a way, that it’s start after a given zoom level. At least don’t cluster so ‘early’.
Question:
What does the parameters mean?
Is it possible to start clustering at given zoom level, during parameters?

Kind regards,
Paul

Re: Delay Cluster effect on WpfMap

Posted: Fri Mar 02, 2018 12:49 pm
by Joost
From the metadata in visual studio:

Code: Select all

//
        // Summary:
        //     Initializes a new instance of the Ptv.XServer.Controls.Map.Tools.TileBasedPointClusterer`1
        //     class.
        //
        // Parameters:
        //   referenceSize:
        //     The logical size of the cluster area.
        //
        //   minLevel:
        //     The minimum level for which clusters should be created.
        //
        //   maxLevel:
        //     The maximum level for which clusters should be created.
        public TileBasedPointClusterer(double referenceSize, int minLevel, int maxLevel);

Re: Delay Cluster effect on WpfMap

Posted: Fri Mar 02, 2018 1:07 pm
by Joost
A bit of trial and error:

From most zoomed int (level 19) until maxLevel the cluster will be caculated based maxLevel zoom
From maxLevel to minLlevel the cluster will be caculated based the actual zoom
From minLlevel until max zoomed out (level 0) the cluster will be caculated based minLlevel zoom

i hope this helps