I was looking into Cesium to find out how Polylines are shown or hidden and I was able to figure out that it is being done at shader level - in the Vertex-shader for Polyline gl_Position for a vertex is manipulated based on the value of show and is translated to ZERO(center of the earth) if Polyline is hidden and remains at its position if Polyline is shown, right?
This is a good approach indeed!
Here is my use-case - I want to visualize a trajectory and want to display it progressively and for that I have to create a PolylineCollection with large number of polylines, to progressively show/hide trajectory I need to play with show value of a polyline. Now, the problem is - this large number of polylines and so many polyline collections are causing FPS drop significantly.
I thought of a way to reduce the number of polylines - What I want do is create a single polyline for the complete trajectory and just pass on the indices to be drawn to the renderer.
This will require changes in the Cesium code, may be extending its classes? Can somebody guide me where to start or what else could be done or if something like this is already being done?