Dynamic points updates in high rate(performances)


Well i got into some problems in my application first of all the main issue is about the performances while add and delete points on the map.

In the extreme situation:

The rate of adding its about 10k points per second.
And on the same time 10k points removed per second.

Now the main problem is that the fps is very low.

I was thinking about some solutions but it seems that i stuck.(try using primitives)

Maybe something wrong with the apporach of delete and add...

By the way he solution that may come is maybe to update the current points but every second another points in random position added and another points deleted.

There is no connection between the added and the removed points.

There is anyway to improve the performances ?


There is a known issue regarding lag when removing a large number of point primitives: https://github.com/AnalyticalGraphicsInc/cesium/issues/3018

I would suggest updating the position and other data for each point instead of removing all of them and adding them all back constantly. You’re likely going to run out of memory with that approach.




As someone who has experience with using Cesium to change a lot of points as quickly as possible, I agree with Hannah that updating is vastly faster than removing them. Even if there is no connection between the two point sets, the update time will be substantially faster if you relocate the points and change their attributes.

Something I often do is initiate a PointPrimitiveCollection with my first set of points, then when I transition to the second set do one of two things:

  • If the second set is larger, relocate and change attributes for all of the first set of points, then add just enough points to fill the second set.
  • If the second set is smaller, relocate the necessary points from the first set, and then hide (using 0.0 alpha color or 0 size) the remaining points.

Using this method, Cesium can handle over 100k points with reasonable refresh times (see https://storm.pps.eosdis.nasa.gov/storm/cesium/HWRF.html and use the time controls for an extreme example) in this manner. In each time step, all of the points are relocated, some are added or hidden, and many of them change color.

If you are looking more at animation (multiple frames per second), this approach can also work, although you will have to do some testing to find a happy medium between updates/second and number of points.

-Matt Lammers-

Thank you for sharing, Matt! Your perspective is very much appreciated. :slight_smile:


  • Rachel