This application has it's own scene tree in which sessions store their computed outputs, but you can also create, adjust and remove parts of the scene tree yourself. (Example: In some cases you might want to adjust the geometry that you get back from our servers. You might want to hide some objects first, or simply don't want to display them at all. In most cases, there is no need to adjust the scene tree though.)
The scene tree is a tree structure with a single root node. Every node can have any number of children and data items. The data items contain the actual information, whereas the nodes are only used to maintain and manage the hierarchy.
Data items can simply be changed and adjusted. Only the version of the data item has to be updated to notify the renderer that a change has happened.
Before we do anything, the scene tree has already been created. There is nothing in it besides the root node. So let's just look at how the scene tree looks after we create a single session. Our scene tree now change as a node was added automatically. Let's assume, the session has two outputs with one content each. Then the scene tree will look like this:
Please note that the geometry and data items will not be directly in these nodes. This visualization is simplified. In reality, there are many more children that depict the hierarchy of the geometry.
If we would customize the scene again, every output that is loaded again would be overwritten. Therefore, we now save our session node by copying it. Additionally, we translate it to see both at once.
Adjusting the Scene tree
Let's now customize the scene again.
The result is now that we have the geometry two times, once in the old configuration and once in the new configuration.
Traversing the Scene Tree
You can traverse the scene tree and its data by using the utility functions