Delay Cluster effect on WpfMap

Within this forum we want to offer discussions all around our .NET based Map control including all .Net-language specific questions concerning calls of the xServer-API. Attention: xServer-relevant concepts can be found in further forums such as xRoute or xTour.

Delay Cluster effect on WpfMap

Postby PaulBuechs » Thu Feb 22, 2018 6:24 pm

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
User avatar
PaulBuechs
 
Posts: 21
Joined: Tue Mar 28, 2017 1:09 pm

Re: Delay Cluster effect on WpfMap

Postby Joost » Fri Mar 02, 2018 12:49 pm

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);
Joost Claessen
Senior Technical Consultant
PTV Benelux
Joost
 
Posts: 232
Joined: Fri Apr 25, 2014 1:46 pm

Re: Delay Cluster effect on WpfMap

Postby Joost » Fri Mar 02, 2018 1:07 pm

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
Joost Claessen
Senior Technical Consultant
PTV Benelux
Joost
 
Posts: 232
Joined: Fri Apr 25, 2014 1:46 pm


Return to PTV xServer.NET (Admin=OH)

cron