Object State
The object state object, represents the data that flows through the pipeline. When the Object::Eval()
method is called on an object or a derived object, it returns an ObjectState
. This is passed from one object reference to the next. The ObjectState
contains the following elements:
- Object pointer - A modifier will often refer to the object in the pipeline using this pointer. The object pointer is a public data member of type
Object*
and is defined asObjectState::obj
. - Transformation matrix - The object state manages a transformation matrix (
ObjectState::GetTM
()) that is deformed only if an object cannot convert itself to a deformable type. After the matrix is deformed, it is converted back into an matrix using an iterative process that 'averages' the axis. All objects are supposed to be able to convert themselves toTriObject
s (which are deformable) so in general this is not used. However in the case of cameras and lights it doesn't make sense to convert them toTriObject
s so this is how they are deformed. You can see an example of this by binding a camera to a space warp like ripple. The camera will bounce up and down as it is 'deformed' by the space warp.