![]() |
VR-Forces 4.1.1 Class Documentation
|
Abstract scene object updater interface. More...

Public Member Functions | |
| DtSceneObjectUpdater (DtDe &de, DtUniqueID id, bool suppressTick=false) | |
| CTOR. | |
| virtual | ~DtSceneObjectUpdater () |
| Virtual DTOR. | |
| virtual bool | needsUpdate (DtTime tNow) |
| The check function called by DtTickableManager to verify if an update is required. | |
| virtual void | update (DtTime tNow)=0 |
| The update function called by DtTickableManager during update-ticks. | |
| virtual DtTime | lastUpdateTime () const |
| Get the time-stamp of the last update. | |
| virtual void | setSceneObject (DtSceneObject *sceneObject) |
| Set the scene object to be updated. | |
| DtSceneObject * | findSceneObject () |
| Get the current scene object for this updater. | |
| DtUniqueID | uniqueId () const |
| Returns the distributed object id of this updater. | |
| virtual void | setUpdaterPosition (int vtx, const DtVector &pos) |
| Set the position of a scene object vertex. | |
| virtual const DtVector & | updaterPosition (int vtx) const |
| Get the position of a scene object vertex. | |
| virtual void | setUpdaterOrientation (int vtx, const DtTaitBryan &ori) |
| Set the orientation of a scene object vertex. | |
| virtual const DtTaitBryan & | updaterOrientation (int vtx) const |
| Get the orientation of a scene object vertex. | |
| void | updateSceneObject (DtTime tNow) |
| Update the scene object position and orientation at each vertex and set the last updated time-stamp. | |
| virtual void | terrainScaleTransformsIfNeeded () |
| Scales the transforms if the terrain scaling flag is set. | |
Protected Attributes | |
| DtDe & | myDe |
| The display engine. | |
| DtUniqueID | myUniqueId |
| This distributed object's unique identifier. | |
| DtSceneObject * | mySceneObject |
| A pointer to the current scene object being updated. | |
| DtTime | myLastUpdateTime |
| The last time stamp when the updateSceneObject() was called. | |
| DtSceneObject::TransformList | myTransforms |
| Local copy of the vertex positions and orientations. | |
| const DtDeSharedState & | myDeSharedState |
| This is kept to make terrain scale updating cheaper ( by one virtual function call ). | |
| bool | myInManager |
| If tick was suppressed, then this updater is not on the tickableManager. | |
Private Member Functions | |
| DtSceneObject::ObjectTransform & | getOrCreateTransform (int vtx) |
| Helper function to get the transform at a given vertex. | |
| const DtSceneObject::ObjectTransform & | getTransform (int vtx) const |
| Helper function to get the transform at a given vertex. | |
Signals | |
| boost::signal< void(const DtUniqueID &) > | signal_updaterToBeDeleted |
| Signal that this updater is being destroyed. | |
| virtual void | slot_sceneObjectToBeDeleted (const DtUniqueID &id) |
| Signal that this updater is being destroyed. | |
Additional Inherited Members | |
Protected Member Functions inherited from makVrv::DtTickable | |
| DtTickable (DtTickableManagerInterface *manager=NULL) | |
| CTOR. | |
| virtual | ~DtTickable () |
| Virtual DTOR. | |
Abstract scene object updater interface.
DtSceneObjectUpdaters are distributed objects, managed by DtTickableManager. They update the position and orientation of scene objects during the manager 'tick' update.
| makVrv::DtSceneObjectUpdater::DtSceneObjectUpdater | ( | DtDe & | de, |
| DtUniqueID | id, | ||
| bool | suppressTick = false |
||
| ) |
CTOR.
| [in] | de | is the display engine. |
| [in] | id | is a unique identifier for this distributed object. |
| [in] | suppressTick | is a flag instructing to not register with a DtTickableManager when set true, default is false. |
|
virtual |
Virtual DTOR.
|
virtual |
The check function called by DtTickableManager to verify if an update is required.
If this function returns true, the DtTickableManager will then call update().
| [in] | tNow | is the current time-stamp. |
| true | if this object needs to be ticked. |
| false | otherwise. |
Implements makVrv::DtTickable.
|
pure virtual |
The update function called by DtTickableManager during update-ticks.
| [in] | tNow | is the current time-stamp. |
Implements makVrv::DtTickable.
Implemented in makVrv::DtAttachableUpdater, makVrv::DtAttachableEntityFanUpdater, makVrv::DtLineModelUpdater, makVrv::DtSegmentedLineModelUpdater, makVrv::DtMultiDeadReckonUpdater, makVrv::DtGroundClampingUpdater, makVrv::DtDeadReckonGroundClampUpdater, makVrv::DtAttachableDeadReckonUpdater, makVrv::DtAttachableIntervisibilityUpdater, makVrv::DtDeadReckonUpdater, makVrv::DtTrackHistoryUpdater, and makVrv::DtHeadingLineUpdater.
|
virtual |
Get the time-stamp of the last update.
|
virtual |
Set the scene object to be updated.
| [in] | sceneObject | is the scene object to receive updates. |
Reimplemented in makVrv::DtAttachableDeadReckonUpdater, makVrv::DtLineModelUpdater, makVrv::DtSegmentedLineModelUpdater, makVrv::DtDeadReckonGroundClampUpdater, makVrv::DtDeadReckonUpdater, makVrv::DtTrackHistoryUpdater, and makVrv::DtHeadingLineUpdater.
|
inline |
Get the current scene object for this updater.
|
inline |
Returns the distributed object id of this updater.
|
virtual |
Set the position of a scene object vertex.
| [in] | vtx | is the vertex of the scene object. |
| [in] | pos | is the position to set. |
|
virtual |
Get the position of a scene object vertex.
| [in] | vtx | is the vertex of the scene object. |
|
virtual |
Set the orientation of a scene object vertex.
| [in] | vtx | is the vertex of the scene object. |
| [in] | ori | is the orientation to set. |
|
virtual |
Get the orientation of a scene object vertex.
| [in] | vtx | is the vertex of the scene object. |
| void makVrv::DtSceneObjectUpdater::updateSceneObject | ( | DtTime | tNow | ) |
Update the scene object position and orientation at each vertex and set the last updated time-stamp.
| [in] | tNow | is the current time-stamp. |
Reimplemented in makVrv::DtLineModelUpdater, makVrv::DtSegmentedLineModelUpdater, makVrv::DtAttachableEntityFanUpdater, makVrv::DtAttachableIntervisibilityUpdater, and makVrv::DtAttachableFanUpdater.
|
virtual |
Scales the transforms if the terrain scaling flag is set.
|
protectedvirtual |
Signal that this updater is being destroyed.
|
private |
Helper function to get the transform at a given vertex.
If the vertex is above range, new transforms are created.
| [in] | vtx | is the vertex of the transform to get. |
| DtCorruptedState | if vtx is less than zero. |
|
private |
Helper function to get the transform at a given vertex.
If the vertex is out of range, a 'zero' transform is returned.
| [in] | vtx | is the vertex of the transform to get. |
| boost::signal< void ( const DtUniqueID& ) > makVrv::DtSceneObjectUpdater::signal_updaterToBeDeleted |
Signal that this updater is being destroyed.
|
protected |
The display engine.
|
protected |
This distributed object's unique identifier.
|
protected |
A pointer to the current scene object being updated.
|
protected |
The last time stamp when the updateSceneObject() was called.
|
protected |
Local copy of the vertex positions and orientations.
These are typically pre-calculated, and then pushed to the scene object at a later time, making the concatenation of updaters simpler.
|
protected |
This is kept to make terrain scale updating cheaper ( by one virtual function call ).
|
protected |
If tick was suppressed, then this updater is not on the tickableManager.
In this case, the scene object is not given a pointer to this updater