![]() |
Murl Engine Lua Addon API
Version 1.0 beta
|
The ISubState graph node interface.
Graph::ISubState nodes can be used to encapsulate scene graph traversal state changes, so that the user does not have to track all changes to e.g. material states, texture states etc.
By default, when it gets initialized, a sub state node determines the states that get actually changed during traversal of its sub-graph. When the scene graph gets traversed, only those states are preserved. It is possible to manually override this behavior by setting a state bit mask via SetPreservedStatesIncludeMask() and SetPreservedStatesExcludeMask(), to either include additional preserved states or force the node to not include specific ones.
State preserving is not free; the more states are changing within the sub-graph, the more information must be kept at each traversal. Especially when a lot of texture and/or material state slots are involved, this can be a costly operation.
Get the constant Graph::INode interface. This method returns a constant pointer to the node's Graph::INode interface, to be able to query common node properties such as active state, visibility or ID.
Murl.Graph.INode GetNodeInterface()
Set the traversal states to be preserved.
Boolean SetPreservedStatesIncludeMask(Integer mask)
mask | A bit mask of individual traversal states. See IEnums::TraversalState. |
Get the traversal states to be preserved.
Integer GetPreservedStatesIncludeMask()
Set the traversal states to be explicitly not preserved.
Boolean SetPreservedStatesExcludeMask(Integer mask)
mask | A bit mask of individual traversal states. See IEnums::TraversalState. |
Get the traversal states to be explicitly not preserved.
Integer GetPreservedStatesExcludeMask()