VR-Forces 4.7 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes | Friends
makVrv::DtDriver Class Reference

The DtDriver is an abstract class. More...

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

Public Member Functions

 DtDriver (DtAgentManager &agentManager, const std::string &instanceName)
 CTOR.
virtual ~DtDriver ()
 DTOR.
virtual void realizeConfiguration (const DtConfiguration &configuration)
 Realize the driver using the configuration.
virtual DtConfiguration createConfiguration () const
 Create a configuration for the driver.
DtAgentManageragentManager ()
 Get the master scene for this host.
virtual DtAgentManagerInterfacesceneInterface ()
 Get the scene manager interface for creating agents.
bool started () const
 Get this driver's active state.
virtual const std::string & className () const =0
 Get this driver's class name.
virtual const std::string & instanceName () const
 Get this driver's instance name.
virtual bool autoStart () const
 Get whether this driver is set to automatically start if it is persistent.
virtual void setAutoStart (bool autoStart)
 Set whether this driver automatically starts if it is persistent.
virtual bool isWindowDependent () const
 Get whether this driver is set to automatically start when the first window is created and stop when the last window is destroyed.
virtual void setIsWindowDependent (bool dep)
 Set whether this driver is set to automatically start when the first window is created and stop when the last window is destroyed.
virtual void setIsUserControllable (bool)
 Set whether this driver can be started and stopped by the user.
virtual bool isUserControllable () const
 Get whether this driver can be started and stopped by the user.
virtual void setIsPersistent (bool per)
 Set if the driver is persistent and should be saved between runs.
virtual bool isPersistent () const
 Get if the driver is persistent and should be saved between runs.
virtual bool isOnDriverSelectionList () const
 Returns whether or not this driver is to be automatically started/stopped from the driver selection list.
virtual void setOnDriverSelectionList (bool)
 Sets whether or not this item is on the driver selection list.
bool objectFromAgentManager (const DtUniqueID &id) const
 check to see if the object was created using this driver's agent manager.

Protected Member Functions

void applyChangesAndDelete (DtElementChanges *changes)
 Function for apply changes from a changes object and deleting it.
void reportElementCreated (DtElementID id, DtElementID parentId, DtElementEntry::ElementType type)
 Report an element created.
void reportElementAttribute (DtElementID id, DtElementAttribute *attribute)
 Report an element attribute changed.
void reportElementDestroyed (DtElementID id)
 Report an element destroyed.
void start ()
 Start the driver.
void stop ()
 Stop the driver.
bool tick ()
 Tick the host driver.
virtual bool onStart ()=0
 Start the host output.
virtual bool onStop ()=0
 Stop the host output.
virtual bool onTick ()=0
 Tick.
virtual void slot_displayEngineAdded (const DtDeRecord &igRecord)
 Called when a display engine is added.
virtual void setInstanceName (const std::string &name)
 set the Instance name.
virtual void installAccessories ()
 Installs accessories on this driver.
virtual void uninstallAccessories ()
 Removes accessories from this driver.

Protected Attributes

DtAgentManagermyAgentManager
bool myStartedFlag
std::string myName
DtConfiguration myConfiguration
bool myPersistentFlag
bool myUserControllableFlag
bool myRequestStateDiffPendingFlag
DtElementChanges myChanges

Friends

class DtDriverManager

Detailed Description

The DtDriver is an abstract class.

Developers derive from this to create logic that "directs" things in the VRV framework.

Examples

Constructor & Destructor Documentation

makVrv::DtDriver::DtDriver ( DtAgentManager agentManager,
const std::string &  instanceName 
)

CTOR.

virtual makVrv::DtDriver::~DtDriver ( )
virtual

DTOR.

Member Function Documentation

virtual void makVrv::DtDriver::realizeConfiguration ( const DtConfiguration configuration)
virtual
virtual DtConfiguration makVrv::DtDriver::createConfiguration ( ) const
virtual
DtAgentManager& makVrv::DtDriver::agentManager ( )

Get the master scene for this host.

Do not create drivers using this agentManager, use the sceneInterface as it may replaced the implementation of the sceneInterface.

virtual DtAgentManagerInterface& makVrv::DtDriver::sceneInterface ( )
virtual

Get the scene manager interface for creating agents.

Reimplemented in makVrv::DtCigiDriver.

bool makVrv::DtDriver::started ( ) const
inline

Get this driver's active state.

virtual const std::string& makVrv::DtDriver::className ( ) const
pure virtual

Get this driver's class name.

Implemented in makVrv::DtIntervisibilityDriver, makVrv::DtInputDriver, makVrv::DtVirtualRealityDriver, makVrv::DtSceneDriver, makVrv::exampleSymbolFacade3::DtExampleSymbolDriver, ForestDriver, makVrv::exampleSymbolFacade5::DtExampleSymbolDriver, makVrv::exampleSymbolFacade4::DtExampleSymbolDriver, makVrv::DtCigiDriver, makVrv::exampleSymbolFacade2::DtExampleSymbolDriver, makVrv::DtVrlinkDriver, DtGimbalDriver, makVrv::exampleSymbolFacade1::DtExampleSymbolDriver, DtExampleThreadedDriver, DtExampleEffectsDriver, makVrv::exampleTacticalGraphics::DtExampleTacticalGraphicsDriver, DtExampleTrackHistoryDriver, makVrv::tutorialDistributedSimulation5::DistributedSimulationDriver, DtExampleCommLinesDriver, makVrv::DtExampleProjectile, DtStateViewDriver, makVrv::vrvExampleCloudDriver::DtCloudDriver, makVrv::DtGlStudioDriver, makVrv::tutorialDistributedSimulation3B::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3D::DistributedSimulationDriver, makVrv::DtUnknownDriver, makVrv::DtConnectionObjectsDriver, makVrv::tutorialDistributedSimulation2B::DistributedSimulationDriver, DtExampleDriver, makVrv::tutorialDistributedSimulation4B::DistributedSimulationDriver, DtDistributedDrawDriver, makVrv::tutorialDistributedSimulation3A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation1::DistributedSimulationDriver, and makVrv::tutorialDistributedSimulation2A::DistributedSimulationDriver.

virtual const std::string& makVrv::DtDriver::instanceName ( ) const
virtual

Get this driver's instance name.

virtual bool makVrv::DtDriver::autoStart ( ) const
virtual

Get whether this driver is set to automatically start if it is persistent.

Reimplemented in makVrv::DtIntervisibilityDriver.

virtual void makVrv::DtDriver::setAutoStart ( bool  autoStart)
virtual

Set whether this driver automatically starts if it is persistent.

virtual bool makVrv::DtDriver::isWindowDependent ( ) const
virtual

Get whether this driver is set to automatically start when the first window is created and stop when the last window is destroyed.

virtual void makVrv::DtDriver::setIsWindowDependent ( bool  dep)
virtual

Set whether this driver is set to automatically start when the first window is created and stop when the last window is destroyed.

virtual void makVrv::DtDriver::setIsUserControllable ( bool  )
virtual

Set whether this driver can be started and stopped by the user.

virtual bool makVrv::DtDriver::isUserControllable ( ) const
virtual

Get whether this driver can be started and stopped by the user.

Reimplemented in makVrv::DtUnknownDriver.

virtual void makVrv::DtDriver::setIsPersistent ( bool  per)
virtual

Set if the driver is persistent and should be saved between runs.

virtual bool makVrv::DtDriver::isPersistent ( ) const
virtual

Get if the driver is persistent and should be saved between runs.

virtual bool makVrv::DtDriver::isOnDriverSelectionList ( ) const
virtual

Returns whether or not this driver is to be automatically started/stopped from the driver selection list.

virtual void makVrv::DtDriver::setOnDriverSelectionList ( bool  )
virtual

Sets whether or not this item is on the driver selection list.

Will be saved to record if state is different

bool makVrv::DtDriver::objectFromAgentManager ( const DtUniqueID id) const

check to see if the object was created using this driver's agent manager.

void makVrv::DtDriver::applyChangesAndDelete ( DtElementChanges changes)
protected

Function for apply changes from a changes object and deleting it.

This function is useful for queuing from an external thread as a means of passing changes from a secondary thread back to the main thread.

void makVrv::DtDriver::reportElementCreated ( DtElementID  id,
DtElementID  parentId,
DtElementEntry::ElementType  type 
)
protected

Report an element created.

void makVrv::DtDriver::reportElementAttribute ( DtElementID  id,
DtElementAttribute attribute 
)
protected

Report an element attribute changed.

Note
The attribute passed in should not be used again.
void makVrv::DtDriver::reportElementDestroyed ( DtElementID  id)
protected

Report an element destroyed.

void makVrv::DtDriver::start ( )
protected

Start the driver.

Called by the Master Scene. Calls installAccessories().

void makVrv::DtDriver::stop ( )
protected

Stop the driver.

Called by the Master Scene. Calls uninstallAccessories().

bool makVrv::DtDriver::tick ( )
protected

Tick the host driver.

Called by the Master Scene.

Return values
trueif tick succeeded.
falseif the host must be stopped.
virtual bool makVrv::DtDriver::onStart ( )
protectedpure virtual

Start the host output.

Create all objects for an existing host connection.

Return values
trueif start succeeded
falseotherwise.

Implemented in makVrv::DtIntervisibilityDriver, makVrv::DtVrlinkDriver, makVrv::DtCigiDriver, makVrv::DtVirtualRealityDriver, DtExampleThreadedDriver, makVrv::DtInputDriver, makVrv::exampleSymbolFacade3::DtExampleSymbolDriver, makVrv::exampleSymbolFacade5::DtExampleSymbolDriver, makVrv::exampleSymbolFacade4::DtExampleSymbolDriver, makVrv::DtGlStudioDriver, DtGimbalDriver, makVrv::exampleSymbolFacade2::DtExampleSymbolDriver, makVrv::DtSceneDriver, makVrv::exampleSymbolFacade1::DtExampleSymbolDriver, DtStateViewDriver, DtExampleEffectsDriver, makVrv::exampleTacticalGraphics::DtExampleTacticalGraphicsDriver, DtDistributedDrawDriver, ForestDriver, DtExampleTrackHistoryDriver, makVrv::tutorialDistributedSimulation5::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation2B::DistributedSimulationDriver, makVrv::DtExampleProjectile, DtExampleCommLinesDriver, makVrv::DtUnknownDriver, makVrv::vrvExampleCloudDriver::DtCloudDriver, makVrv::tutorialDistributedSimulation3B::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3D::DistributedSimulationDriver, makVrv::DtConnectionObjectsDriver, makVrv::tutorialDistributedSimulation4B::DistributedSimulationDriver, DtExampleDriver, makVrv::tutorialDistributedSimulation3A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation1::DistributedSimulationDriver, and makVrv::tutorialDistributedSimulation2A::DistributedSimulationDriver.

virtual bool makVrv::DtDriver::onStop ( )
protectedpure virtual

Stop the host output.

All scene object created by the host should be destroyed.

Return values
trueif stop succeeded.
falseotherwise.

Implemented in makVrv::DtIntervisibilityDriver, makVrv::DtVrlinkDriver, makVrv::DtCigiDriver, makVrv::DtVirtualRealityDriver, DtExampleThreadedDriver, makVrv::DtInputDriver, makVrv::exampleSymbolFacade3::DtExampleSymbolDriver, makVrv::exampleSymbolFacade5::DtExampleSymbolDriver, makVrv::exampleSymbolFacade4::DtExampleSymbolDriver, DtGimbalDriver, makVrv::DtGlStudioDriver, makVrv::exampleSymbolFacade2::DtExampleSymbolDriver, makVrv::DtSceneDriver, makVrv::exampleSymbolFacade1::DtExampleSymbolDriver, DtExampleEffectsDriver, DtStateViewDriver, makVrv::exampleTacticalGraphics::DtExampleTacticalGraphicsDriver, ForestDriver, DtDistributedDrawDriver, DtExampleTrackHistoryDriver, makVrv::tutorialDistributedSimulation5::DistributedSimulationDriver, makVrv::DtExampleProjectile, makVrv::tutorialDistributedSimulation2B::DistributedSimulationDriver, DtExampleCommLinesDriver, makVrv::DtUnknownDriver, makVrv::vrvExampleCloudDriver::DtCloudDriver, makVrv::tutorialDistributedSimulation3B::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3D::DistributedSimulationDriver, makVrv::DtConnectionObjectsDriver, DtExampleDriver, makVrv::tutorialDistributedSimulation4B::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation1::DistributedSimulationDriver, and makVrv::tutorialDistributedSimulation2A::DistributedSimulationDriver.

virtual bool makVrv::DtDriver::onTick ( )
protectedpure virtual

Tick.

Return values
trueif tick succeeded.
falseotherwise.

Implemented in makVrv::DtIntervisibilityDriver, makVrv::DtVrlinkDriver, makVrv::DtCigiDriver, makVrv::DtVirtualRealityDriver, DtExampleThreadedDriver, DtGimbalDriver, makVrv::exampleSymbolFacade3::DtExampleSymbolDriver, makVrv::DtInputDriver, makVrv::exampleSymbolFacade5::DtExampleSymbolDriver, makVrv::exampleSymbolFacade4::DtExampleSymbolDriver, makVrv::DtGlStudioDriver, makVrv::exampleSymbolFacade2::DtExampleSymbolDriver, makVrv::exampleSymbolFacade1::DtExampleSymbolDriver, makVrv::DtSceneDriver, DtStateViewDriver, DtDistributedDrawDriver, DtExampleEffectsDriver, makVrv::exampleTacticalGraphics::DtExampleTacticalGraphicsDriver, DtExampleTrackHistoryDriver, ForestDriver, makVrv::DtExampleProjectile, makVrv::tutorialDistributedSimulation5::DistributedSimulationDriver, DtExampleCommLinesDriver, makVrv::tutorialDistributedSimulation2B::DistributedSimulationDriver, makVrv::DtUnknownDriver, makVrv::vrvExampleCloudDriver::DtCloudDriver, makVrv::tutorialDistributedSimulation3B::DistributedSimulationDriver, makVrv::DtConnectionObjectsDriver, makVrv::tutorialDistributedSimulation3D::DistributedSimulationDriver, DtExampleDriver, makVrv::tutorialDistributedSimulation4B::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation3C::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation4A::DistributedSimulationDriver, makVrv::tutorialDistributedSimulation1::DistributedSimulationDriver, and makVrv::tutorialDistributedSimulation2A::DistributedSimulationDriver.

virtual void makVrv::DtDriver::slot_displayEngineAdded ( const DtDeRecord igRecord)
protectedvirtual
virtual void makVrv::DtDriver::setInstanceName ( const std::string &  name)
protectedvirtual

set the Instance name.

Note
Only called by the sim driver manager. Renaming is treated as destroying and adding the same driver with a different name.
virtual void makVrv::DtDriver::installAccessories ( )
protectedvirtual

Installs accessories on this driver.

The compatible and enabled accessories in the DtDriverManager's accessory map are installed on this driver.

virtual void makVrv::DtDriver::uninstallAccessories ( )
protectedvirtual

Removes accessories from this driver.

The compatible and enabled accessories in the DtDriverManager's accessory map are removed from this driver.

Friends And Related Function Documentation

friend class DtDriverManager
friend

Member Data Documentation

DtAgentManager& makVrv::DtDriver::myAgentManager
protected
bool makVrv::DtDriver::myStartedFlag
protected
std::string makVrv::DtDriver::myName
protected
DtConfiguration makVrv::DtDriver::myConfiguration
protected
bool makVrv::DtDriver::myPersistentFlag
protected
bool makVrv::DtDriver::myUserControllableFlag
protected
bool makVrv::DtDriver::myRequestStateDiffPendingFlag
protected
DtElementChanges makVrv::DtDriver::myChanges
protected

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

Document ID: Generated on Fri Apr 26 21:53:14 EDT 2019 from SVN revision 197883
Copyright © 2005-2019 VT MAK. All Rights Reserved (www.mak.com)