17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-06 17:28:36 +01:00

Cull instances by compact records and draw them from a shader storage buffer

This commit is contained in:
2026-10-16 00:37:54 +02:00
parent fd98d4eea5
commit 9277c28805
13 changed files with 269 additions and 228 deletions

View File

@@ -345,6 +345,10 @@ private:
// changes whenever a node is shown or hidden, or a model instance stops being drawn along with other instances of its
// model. copies of these states (instance records of the renderer) are made anew once it changes
inline unsigned int node_state_version { 1 };
// base interface for nodes which can be actvated in scenario editor
class basic_node {
@@ -460,6 +464,9 @@ basic_node::location() {
inline
void
basic_node::visible( bool const Visible ) {
if( Visible != m_visible ) {
++node_state_version;
}
m_visible = Visible;
}