VR-Forces 4.10 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 | Private Member Functions | Friends
makVrv::DtProp Class Reference

Facade object for a scene prop. More...

Public Member Functions

 DtProp (DtDe &de, DtAgentManagerInterface &agentManagerInterface, const std::string &propType, const std::string &name)
 CTOR Construct a prop from a model definition. More...
 
virtual ~DtProp ()
 DTOR. More...
 
void destroy ()
 Delete the contents of the prop. More...
 
bool operator== (const DtProp &prop) const
 Returns true IFF argument has same type and name. More...
 
bool getRecord (makArchives::DtPropRecord &recOut) const
 Returns true if recOut was filled with all the information about this prop. More...
 
void setFromRecord (const makArchives::DtPropRecord &rec)
 Fill out this prop from the record. More...
 
void setColorFilter (float r, float g, float b, float a)
 Set the multipliers for the prop's color. More...
 
void setVisible (bool isVisible)
 Set the prop visible or not. More...
 
void setScribed (bool isSelected)
 Set the prop has a scribed bounding box. More...
 
bool scribed () const
 Get if the prop has a scribed bounding box. More...
 
DtUniqueID uniqueID () const
 Accessors. More...
 
void getPosition (double &x, double &y, double &z) const
 Get the prop position. More...
 
void setPosition (double x, double y, double z)
 Set the prop position in scene coordinates. More...
 
void getOrientation (double &x, double &y, double &z, double &w) const
 Get the prop orientation. More...
 
void setOrientation (double x, double y, double z, double w)
 Set the prop orientation. More...
 
void setOrientation (double psi, double theta, double phi)
 Set the prop orientation in Euler angles. More...
 
const std::string & propType () const
 Get type of prop (e.g. building, tree, ...) More...
 
void setPropType (const std::string &proptype)
 Change the prop type of this prop. More...
 
const std::string & modelDefinition () const
 Get the model definition. More...
 
void setModelDefinition (const std::string &modelDefinition)
 Set the model definition of a prop. More...
 
void setExternalNodeLocation (const std::string &searchExpression, unsigned int index)
 Set the location of the node moved to this prop from a terrain. More...
 
const std::string & searchExp () const
 Get the expression used to find the prop. More...
 
unsigned int searchIndex () const
 Get the index used to find the prop. More...
 
void setTerrainTreeSettings (DtTerrainTreeSettings *terrainTreeSettings)
 Set tree settings (for when the prop is a tree) More...
 
const DtTerrainTreeSettingsterrainTreeSettings (void) const
 Get the tree settings (for when the prop is a tree) More...
 
const std::string & name () const
 Get the prop's name. More...
 
void setName (const std::string &name)
 Set the props name. More...
 
bool isVisible () const
 
const DtModelAgent * model () const
 Get the prop's distributed model driver. More...
 
DtModelAgent * model ()
 Get the prop's distributed model driver. More...
 
bool operator!= (const DtProp &prop) const
 != operator for props More...
 
float red () const
 Get the current color filter components. More...
 
float green () const
 
float blue () const
 
float alpha () const
 
const DtSceneObjectAgent * sceneObject () const
 Get the prop's distributed scene object driver. More...
 
DtSceneObjectAgent * sceneObject ()
 Get the prop's distributed scene object driver. More...
 

Protected Member Functions

virtual void selectionChanged (const DtSelectionManager::IdSet &selected, const DtSelectionManager::IdSet &deselected)
 

Protected Attributes

DtDemyDe
 
std::string myPropType
 
DtSceneObjectAgent * mySceneObject
 
DtModelAgent * myObjectModel
 
DtScribeBoxModelAgent * myScribeBoxModel
 
std::string myModelDefinition
 The model definition. More...
 
std::string mySearchExp
 The expression that was used to find the prop. More...
 
unsigned int mySearchIndex
 
std::string myName
 The prop's unique name. More...
 
bool myIsVisible
 Whether the prop is visible. More...
 
float myAlpha
 Color components. More...
 
float myR
 
float myG
 
float myB
 
double myPosX
 Position set by DtPropRecord on load. More...
 
double myPosY
 
double myPosZ
 
double myOrientationX
 
double myOrientationY
 
double myOrientationZ
 
double myOrientationW
 
bool myIsTreeFlag
 
DtTerrainTreeSettingsmyTerrainTreeSettings
 
DtAgentManagerInterfacemyAgentManagerInterface
 

Private Member Functions

 DtProp (const DtProp &copy)
 Copy CTOR. More...
 
DtPropoperator= (const DtProp &copy)
 Assignment operator. More...
 

Friends

class DtTerrainLayer
 Befriend the DtTerrainLayer to allow it to manage connection of the selectionChanged slot to the selectionChanged signal of the DtTerrainLayer. More...
 

Detailed Description

Facade object for a scene prop.

Constructor & Destructor Documentation

makVrv::DtProp::DtProp ( DtDe de,
DtAgentManagerInterface agentManagerInterface,
const std::string &  propType,
const std::string &  name 
)

CTOR Construct a prop from a model definition.

makVrv::DtProp::DtProp ( const DtProp copy)
private

Copy CTOR.

virtual makVrv::DtProp::~DtProp ( )
virtual

DTOR.

Member Function Documentation

DtProp& makVrv::DtProp::operator= ( const DtProp copy)
private

Assignment operator.

void makVrv::DtProp::destroy ( )

Delete the contents of the prop.

bool makVrv::DtProp::operator== ( const DtProp prop) const

Returns true IFF argument has same type and name.

bool makVrv::DtProp::getRecord ( makArchives::DtPropRecord recOut) const

Returns true if recOut was filled with all the information about this prop.

void makVrv::DtProp::setFromRecord ( const makArchives::DtPropRecord rec)

Fill out this prop from the record.

void makVrv::DtProp::setColorFilter ( float  r,
float  g,
float  b,
float  a 
)

Set the multipliers for the prop's color.

void makVrv::DtProp::setVisible ( bool  isVisible)

Set the prop visible or not.

void makVrv::DtProp::setScribed ( bool  isSelected)

Set the prop has a scribed bounding box.

bool makVrv::DtProp::scribed ( ) const

Get if the prop has a scribed bounding box.

DtUniqueID makVrv::DtProp::uniqueID ( ) const

Accessors.

Get a unique id.

void makVrv::DtProp::getPosition ( double x,
double y,
double z 
) const

Get the prop position.

void makVrv::DtProp::setPosition ( double  x,
double  y,
double  z 
)

Set the prop position in scene coordinates.

void makVrv::DtProp::getOrientation ( double x,
double y,
double z,
double w 
) const

Get the prop orientation.

void makVrv::DtProp::setOrientation ( double  x,
double  y,
double  z,
double  w 
)

Set the prop orientation.

void makVrv::DtProp::setOrientation ( double  psi,
double  theta,
double  phi 
)

Set the prop orientation in Euler angles.

const std::string& makVrv::DtProp::propType ( ) const

Get type of prop (e.g. building, tree, ...)

void makVrv::DtProp::setPropType ( const std::string &  proptype)

Change the prop type of this prop.

const std::string& makVrv::DtProp::modelDefinition ( ) const

Get the model definition.

void makVrv::DtProp::setModelDefinition ( const std::string &  modelDefinition)

Set the model definition of a prop.

void makVrv::DtProp::setExternalNodeLocation ( const std::string &  searchExpression,
unsigned int  index 
)

Set the location of the node moved to this prop from a terrain.

const std::string& makVrv::DtProp::searchExp ( ) const

Get the expression used to find the prop.

unsigned int makVrv::DtProp::searchIndex ( ) const

Get the index used to find the prop.

void makVrv::DtProp::setTerrainTreeSettings ( DtTerrainTreeSettings terrainTreeSettings)

Set tree settings (for when the prop is a tree)

const DtTerrainTreeSettings* makVrv::DtProp::terrainTreeSettings ( void  ) const

Get the tree settings (for when the prop is a tree)

float makVrv::DtProp::red ( ) const

Get the current color filter components.

float makVrv::DtProp::green ( ) const
float makVrv::DtProp::blue ( ) const
float makVrv::DtProp::alpha ( ) const
const std::string& makVrv::DtProp::name ( ) const

Get the prop's name.

void makVrv::DtProp::setName ( const std::string &  name)

Set the props name.

bool makVrv::DtProp::isVisible ( ) const
const DtSceneObjectAgent* makVrv::DtProp::sceneObject ( ) const

Get the prop's distributed scene object driver.

DtSceneObjectAgent* makVrv::DtProp::sceneObject ( )

Get the prop's distributed scene object driver.

const DtModelAgent* makVrv::DtProp::model ( ) const

Get the prop's distributed model driver.

DtModelAgent* makVrv::DtProp::model ( )

Get the prop's distributed model driver.

bool makVrv::DtProp::operator!= ( const DtProp prop) const

!= operator for props

virtual void makVrv::DtProp::selectionChanged ( const DtSelectionManager::IdSet selected,
const DtSelectionManager::IdSet deselected 
)
protectedvirtual

Friends And Related Function Documentation

friend class DtTerrainLayer
friend

Befriend the DtTerrainLayer to allow it to manage connection of the selectionChanged slot to the selectionChanged signal of the DtTerrainLayer.

Member Data Documentation

DtDe& makVrv::DtProp::myDe
protected
std::string makVrv::DtProp::myPropType
protected
DtSceneObjectAgent* makVrv::DtProp::mySceneObject
protected
DtModelAgent* makVrv::DtProp::myObjectModel
protected
DtScribeBoxModelAgent* makVrv::DtProp::myScribeBoxModel
protected
std::string makVrv::DtProp::myModelDefinition
protected

The model definition.

std::string makVrv::DtProp::mySearchExp
protected

The expression that was used to find the prop.

unsigned int makVrv::DtProp::mySearchIndex
protected
std::string makVrv::DtProp::myName
protected

The prop's unique name.

bool makVrv::DtProp::myIsVisible
protected

Whether the prop is visible.

float makVrv::DtProp::myAlpha
protected

Color components.

float makVrv::DtProp::myR
protected
float makVrv::DtProp::myG
protected
float makVrv::DtProp::myB
protected
double makVrv::DtProp::myPosX
protected

Position set by DtPropRecord on load.

Need because trees require a position when they are added. The scene object doesn't exist yet when the prop is created from the record. Therefore store the position that was loaded from the DtPropRecord.

double makVrv::DtProp::myPosY
protected
double makVrv::DtProp::myPosZ
protected
double makVrv::DtProp::myOrientationX
protected
double makVrv::DtProp::myOrientationY
protected
double makVrv::DtProp::myOrientationZ
protected
double makVrv::DtProp::myOrientationW
protected
bool makVrv::DtProp::myIsTreeFlag
protected
DtTerrainTreeSettings* makVrv::DtProp::myTerrainTreeSettings
protected
DtAgentManagerInterface& makVrv::DtProp::myAgentManagerInterface
protected

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

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)