Hello,
I was trying to use the clustering feature of with the streampoint collection.
I am using the following code to change the appearance of my stream points:
` protected async Task onAfterMapLoaded(RealTimeMap.MapEventArgs args)
{
var realTimeMap = args.sender as RealTimeMap;
args.sender.Geometric.Points.changeExtentWhenAddPoints = false;
args.sender.Geometric.Points.clusteringAfterCollectionUpdate = true;
var points = new List<RealTimeMap.StreamPoint>();
foreach(var x in _buildingLookup.GetLocations())
{
if (x.WayPoint is null) continue;
var point = new RealTimeMap.StreamPoint
{
guid = x.UID, //the use of GUID identification is mandatory
latitude = x.WayPoint.XPos, //the latitude of the map click point
longitude = x.WayPoint.YPos, //the longitude of the map click point
};
points.Add(point);
}
realTimeMap.Geometric.Points.Appearance(item => true).pattern = new RealTimeMap.PointSymbol()
{
radius = 12,
fillColor = "red",
opacity = 1
};
if (points is { Count: > 0 })
{
await realTimeMap.Geometric.Points.upload(points);
}
await InvokeAsync(StateHasChanged);
}`
So the code is just taking some geo-locations and add them to the Geometric.Points. In my dataset are some geo-locations close together, so
I see on my map a cluster and and one red circle. When I am now press F5 to refresh the browse, the stream-points disappear.
I was then testing some of your samples like Working with StreamPoint/Clustering/clustering. And here the same thing happen when refreshing the browser.
Hello,
I was trying to use the clustering feature of with the streampoint collection.
I am using the following code to change the appearance of my stream points:
` protected async Task onAfterMapLoaded(RealTimeMap.MapEventArgs args)
{
}`
So the code is just taking some geo-locations and add them to the Geometric.Points. In my dataset are some geo-locations close together, so
I see on my map a cluster and and one red circle. When I am now press F5 to refresh the browse, the stream-points disappear.
I was then testing some of your samples like Working with StreamPoint/Clustering/clustering. And here the same thing happen when refreshing the browser.