Add culling for 3D glyphs rendering
1 million instances of the stanford bunny (4968 triangles) rendered in real time
In some cases, when the user tries to render thousands instances of a complex model resulting on millions (or even billions) of triangles, the GPU is not able to render the scene in acceptable frame rates.
This MR tackles this problem by culling instances inside the frustum view and adds level of details.
This is done in two passes :
- "Dry-render" each instance point and fill transform feedback LOD buffers (or discard the instance) based on their distance to the camera using geometry shader vertex streams.
- Render each LOD instances buffer using a decimated polydata.
Edited by Michael Migliore