VR-Forces 5.0.2 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Public Attributes
makVrv::DtTickableManagerInterface Class Referenceabstract

An abstract interface for managers of DtTickable objects.

Inheritance diagram for makVrv::DtTickableManagerInterface:
Inheritance graph
[legend]

Public Member Functions

virtual ~DtTickableManagerInterface ()
 
virtual bool addTickableObject (DtTickable *ticObj)=0
 
virtual bool addTickableObjectToMainList (DtTickable *ticObj)=0
 
virtual bool addTickableObjectToThreadSafeList (DtTickable *ticObj)=0
 
virtual void removeTickableObject (DtTickable *ticObj)=0
 
virtual void removeTickableObjectFromMainList (DtTickable *ticObj)=0
 
virtual void removeTickableObjectFromThreadSafeList (DtTickable *ticObj)=0
 
virtual void tick (DtTime tNow=0.0)=0
 
virtual bool inTick ()=0
 
virtual int numTickables ()=0
 
virtual int numMultithreadedTickables ()=0
 
virtual int numTickedLastFrame ()=0
 
virtual double timeSpentThisFrame ()=0
 
virtual bool useAdaptiveTickRate ()=0
 
virtual void setUseAdaptiveTickRate (bool value)=0
 
virtual void resetAdaptiveTickrate ()=0
 
virtual void setUseMultithreadUpdate (bool useIt)=0
 
virtual bool useMultithreadUpdate () const =0
 

Public Attributes

boost::signalslib::signal< void()> signal_aboutToBeDeleted
 

Constructor & Destructor Documentation

virtual makVrv::DtTickableManagerInterface::~DtTickableManagerInterface ( )
virtual

Virtual DTOR.

Member Function Documentation

virtual bool makVrv::DtTickableManagerInterface::addTickableObject ( DtTickable ticObj)
pure virtual

Add a DtTickable object to this manager.

Parameters
[in]ticObjis a pointer to a tick-able object to add.
Return values
trueif the pointer was successfully added.
falseotherwise. This call checks DtTickable::isThreadSafe() and places the tickable on the appropriate tickable list

Implemented in makVrv::DtTickableManager.

virtual bool makVrv::DtTickableManagerInterface::addTickableObjectToMainList ( DtTickable ticObj)
pure virtual

Add a tickable to the main (not threaded) tickable list Even if a tickable is 'thread safe' we may choose to not place it on the threaded list (mainly because it may be a scene object updater at the head of a not thread safe updater chain). This method sets the tickable's tickableListState to DtTickable::TickableOnMainList.

Implemented in makVrv::DtTickableManager.

virtual bool makVrv::DtTickableManagerInterface::addTickableObjectToThreadSafeList ( DtTickable ticObj)
pure virtual

Add a tickable to the threaded tickable list. This method checks the tickable's isThreadSafe() method and will not add the tickable to the list if not thread-safe. This method sets the tickable's tickableListState to DtTickable::TickableOnThreadSafeList.

Implemented in makVrv::DtTickableManager.

virtual void makVrv::DtTickableManagerInterface::removeTickableObject ( DtTickable ticObj)
pure virtual

Remove a DtTickable object from this manager.

Parameters
[in]ticObjis a pointer to a tick-able object to remove. Note: This form is kept for back compatibility. It is inefficient because it needs to check both tickable lists for the tickable to remove. The preferred method is to check the tickable for which list it's on (DtTickable::tickableListState()) and then explicitly remove it from the correct list

Implemented in makVrv::DtTickableManager.

virtual void makVrv::DtTickableManagerInterface::removeTickableObjectFromMainList ( DtTickable ticObj)
pure virtual

Remove a tickable from this manager's main (unthreaded) tickable list. This method sets the tickable's tickableListState to DtTickable::TickableNotOnList.

Implemented in makVrv::DtTickableManager.

virtual void makVrv::DtTickableManagerInterface::removeTickableObjectFromThreadSafeList ( DtTickable ticObj)
pure virtual

Remove a tickable from this manager's thread-safe tickable list. This method sets the tickable's tickableListState to DtTickable::TickableNotOnList.

Implemented in makVrv::DtTickableManager.

virtual void makVrv::DtTickableManagerInterface::tick ( DtTime  tNow = 0.0)
pure virtual

Function to update each tick-able object.

Parameters
[in]tNowis a time-stamp to pass to each object.

Implemented in makVrv::DtTickableManager.

virtual bool makVrv::DtTickableManagerInterface::inTick ( )
pure virtual

returns if the tick manager is currently updating

Implemented in makVrv::DtTickableManager.

virtual int makVrv::DtTickableManagerInterface::numTickables ( )
pure virtual

how many tickables there are total

Implemented in makVrv::DtTickableManager.

virtual int makVrv::DtTickableManagerInterface::numMultithreadedTickables ( )
pure virtual

how many tickables there are, having been filtered by the modelset vector

Implemented in makVrv::DtTickableManager.

virtual int makVrv::DtTickableManagerInterface::numTickedLastFrame ( )
pure virtual

how many tickables were ticked last frame

Implemented in makVrv::DtTickableManager.

virtual double makVrv::DtTickableManagerInterface::timeSpentThisFrame ( )
pure virtual

how long the last update took in seconds

Implemented in makVrv::DtTickableManager.

virtual bool makVrv::DtTickableManagerInterface::useAdaptiveTickRate ( )
pure virtual

are objects calling setUpdatePeriod on themselves when they are updated.

Implemented in makVrv::DtTickableManager.

virtual void makVrv::DtTickableManagerInterface::setUseAdaptiveTickRate ( bool  value)
pure virtual

brief should objects attempt to call setUpdatePeriod on themselves with reasonable values.

Implemented in makVrv::DtTickableManager.

virtual void makVrv::DtTickableManagerInterface::resetAdaptiveTickrate ( )
pure virtual

resets the tickables back to an update period of 1 frame

Implemented in makVrv::DtTickableManager.

virtual void makVrv::DtTickableManagerInterface::setUseMultithreadUpdate ( bool  useIt)
pure virtual

Set the flag that determines whether tickables on the threadsafe list are updated in a parallel_for.

Implemented in makVrv::DtTickableManager.

virtual bool makVrv::DtTickableManagerInterface::useMultithreadUpdate ( ) const
pure virtual

Get the flag that determines whether tickables on the threadsafe list are updated in a parallel_for.

Implemented in makVrv::DtTickableManager.

Member Data Documentation

boost::signalslib::signal<void ()> makVrv::DtTickableManagerInterface::signal_aboutToBeDeleted

The documentation for this class was generated from the following file:

Document ID: Generated on Sun Dec 4 20:22:03 EST 2022 from SVN revision 249613
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)