This optional callback is called during a single-threaded phase
where memory is usually allocated in preparation for the
multi-threaded evaluation phase. For example, we can use this
callback to attach some pre-thread data to a node. The
BeginEvaluate callback uses the ICENodeContext
object to store the user data allocated.
Warning |
The input and output ports cannot be accessed
through the ICENodeContext
object in this callback, except when the node is set as an element
generator and then only input ports are available. The Evaluate callback can access both
input and output port information. |
Note |
The user data stored in BeginEvaluate or Init is always accessible from the
Evaluate callback. However,
unless the custom node threading mode is single-threading, the
Context::PutUserData
property cannot be used from the Evaluate callback. |