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

OSG implementation of overlay polygon model.

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

Public Types

typedef std::vector< DtUnicodeDtScreenIntervaledTextCollection
 

Public Member Functions

 DtOverlayScreenIntervaledTextModel (DtDe &de, DtUniqueID &id)
 
virtual ~DtOverlayScreenIntervaledTextModel ()
 
virtual void setIsClosedFigure (bool)
 
virtual void setScreenIntervaledTextPrefixAndPostFixSeparator (const std::string &separatorString)
 
virtual void setScreenIntervaledTextPrefix (const std::string &prefixString)
 
virtual void setScreenIntervaledTextPostfix (const std::string &postfixString)
 
virtual void setScreenIntervaledTextCollection (const DtScreenIntervaledTextCollection &)
 
virtual void setScreenIntervaledTextInterval (int intervalInScreenSpaceCM)
 
virtual void setFont (const std::string &fontFile, float fontPointSize)
 
virtual void setTextColor (float r, float g, float b, float a)
 
virtual void setBackgroundColor (float r, float g, float b, float a)
 
virtual void setPosition (int vtx, const DtVector &position)
 
virtual void setVertexList (const vrvTacticalGraphicUtilities::DtVerticesVector &verList)
 
virtual void removePosition (int index)
 
virtual void setGroup (int)
 
virtual void setOrientation (int vtx, const DtTaitBryan &orientation)
 
virtual void setIsSupportModel (bool isSupport)
 
virtual void setEventsEnabled (bool)
 
virtual void setVisible (bool isVisible)
 
virtual void addToScene (const DtUniqueID &sceneObjectId, DtModelSetId modelSet, int visualizerType)
 
virtual void removeFromScene ()
 
virtual void setModelDefinition (const std::string &str)
 
- Public Member Functions inherited from makVrv::DtModel
 DtModel (DtDe &de, DtUniqueID id)
 
virtual ~DtModel ()
 
DtModelInstancecreateModelInstance (const std::string &modelDefName, bool realize=true)
 
virtual const std::string & modelDefinitionName ()
 
virtual void saveModelToFile (const std::string &filename)
 
virtual const std::string & className () const
 
virtual DtUniqueID uniqueId () const
 
unsigned int transformSize () const
 
virtual const DtVectorposition (int vtx=0) const
 
virtual void setPositionOffset (const DtVector &positionOffset)
 
virtual const DtVectorpositionOffset () const
 
virtual void setPositionAndOrientation (int vtx, const DtVector &positionOffset, const DtTaitBryan &orientation)
 
virtual const DtTaitBryan & orientation (int vtx=0) const
 
virtual void setOrientationOffset (const DtTaitBryan &orientationOffset)
 
virtual const DtTaitBryan & orientationOffset () const
 
virtual void enableColorBlending (bool b)
 
virtual void setBlendColor (float r, float g, float b, float a)
 
virtual void getBlendColor (float &r, float &g, float &b, float &a)
 
virtual bool colorBlendingEnabled () const
 
virtual void setColor (float r, float g, float b, float a)
 
virtual void enableLighting (bool l)
 
virtual DtModelSetId modelSet () const
 
const DtVectorboundingBoxExtents () const
 
void getBoundingBoxExtents (double &x, double &y, double &z) const
 
const DtVectorboundingBoxCenter () const
 
virtual void getBoundingBoxCenter (double &x, double &y, double &z) const
 
virtual void getBoundingBoxComponents (DtVector &minimum, DtVector &maximum)
 
void setContributesToBound (bool trueOrFalse)
 
bool contributesToBound () const
 
DtDede ()
 
virtual void setModelInstance (DtModelInstance *modelInstance)
 
virtual void promoteBackgroundModelInstance (const DtModelDefinition &defintion)
 
virtual bool visible () const
 
DtUniqueID sceneObjectId () const
 
virtual void addedToSceneObjectAsProp (const DtUniqueID &sceneObj)
 
virtual void setElementId (DtElementID id)
 
virtual void removedFromSceneObject ()
 
virtual void setSolid (bool isSolid)
 
virtual bool isProp ()
 
virtual void updateMinLastFrameDistance (float distance)
 
virtual void resetLastFrameDistance ()
 
virtual float minLastFrameDistance () const
 
virtual DtModelInstancemodelInstance ()
 
virtual const DtModelInstancemodelInstance () const
 
int visualizerType () const
 
virtual bool supportsMultithreadedLoad ()
 
virtual void backgroundLoad ()
 
virtual void foregroundLoad ()
 
virtual bool isActivelyBackgroundLoading ()
 
virtual DtLoaderHandlegetLoadQueueHandle ()
 

Protected Types

typedef std::map< DtChannel
*, DtOverlayScreenIntervaledTextInstance * > 
ChannelInstances
 
- Protected Types inherited from makVrv::DtModel
typedef std::vector
< ObjectTransform
TransformList
 

Protected Member Functions

virtual void update ()
 
virtual void needsUpdate ()
 
virtual void slot_channelCreated (DtChannel *channel)
 
virtual void slot_channelDestroyed (DtChannelManager *channelManager, DtChannel *channel)
 
virtual void setupInstanceWithCurrentValues (DtOverlayScreenIntervaledTextInstance *, const vrvTacticalGraphicUtilities::DtVerticesVector &)
 
virtual void addedToSceneObject (const DtUniqueID &sceneObj, DtModelSetId modelSet, int visualizerType)
 
- Protected Member Functions inherited from makVrv::DtModel
virtual void addToSceneAsProp (const DtUniqueID &sceneObjectId)
 
virtual void initializeModelInstance ()
 
void slot_modelInstanceChanged (DtModelInstance *instance)
 
virtual void waitAndClearLoadHandle ()
 
virtual void removedFromLoadQueue ()
 
virtual void setDoneBackgroundLoading ()
 
virtual void setActivelyBackgroundLoading ()
 

Protected Attributes

bool myEventsEnabled
 
DtTaitBryan myRotation
 
DtSignalConnectionManager myConnections
 
vrvTacticalGraphicUtilities::DtVerticesVector myVertices
 
std::string myScreenIntervaledTextPrefixPostfixSeparatorString
 
std::string myScreenIntervaledTextPrefixString
 
std::string myScreenIntervaledTextPostfixString
 
ChannelInstances myChannelInstances
 
bool myNeedsUpdate
 
bool myIsClosedFigure
 
DtScreenIntervaledTextCollection myScreenIntervaledTextCollection
 
int myScreenIntervaledTextIntervalInScreenSpaceCM
 
std::string myScreenIntervaledTextFontFile
 
float myScreenIntervaledTextFontPointSize
 
float myTextColor [4]
 
float myBackgroundColor [4]
 
std::string myModelDefinition
 
int myGroup
 
- Protected Attributes inherited from makVrv::DtModel
DtLoaderHandlemyInLoadQueueHandle
 
DtDemyDe
 
const DtUniqueID myUniqueId
 
DtUniqueID myElementId
 
DtUniqueID myParentSceneObjectID
 
bool myColorBlendingEnabled
 
DtModelInstancemyBackgroundModelInstance
 
float myMinLastFrameDistance
 
TransformList myTransforms
 
DtModelInstancemyModelInstance
 
DtModelSetId myModelSet
 
int myVisualizerType
 
bool myContributesToBound
 
bool myIsPropFlag
 
float myBlendColor [4]
 
bool myVisibleFlag
 
DtVector myPositionOffset
 
DtTaitBryan myOrientationOffset
 
std::string myModelDefinitionName
 
bool myRequireModelInstance = true
 

Additional Inherited Members

- Public Attributes inherited from makVrv::DtModel
boost::signalslib::signal
< void(DtModel *)> 
signal_modelToBeDestroyed
 
boost::signalslib::signal
< void(DtModel *)> 
signal_modelChanged
 
boost::signalslib::signal
< bool(DtModel *, bool),
SlotReturnOR
signal_visibilityChangeRequested
 
boost::signalslib::signal
< void(DtModelInstance
*, DtModel *)> 
signal_modelInstanceCreated
 
boost::signalslib::signal
< void(DtModelInstance
*, DtModel *)> 
signal_modelInstanceToBeDestroyed
 
- Static Protected Attributes inherited from makVrv::DtModel
static bool theInittedState
 

Member Typedef Documentation

Constructor & Destructor Documentation

makVrv::DtOverlayScreenIntervaledTextModel::DtOverlayScreenIntervaledTextModel ( DtDe de,
DtUniqueID id 
)

CTOR.

virtual makVrv::DtOverlayScreenIntervaledTextModel::~DtOverlayScreenIntervaledTextModel ( )
virtual

DTOR.

Member Function Documentation

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setFont ( const std::string &  fontFile,
float  fontPointSize 
)
virtual

Set the font that the perimeter wrapped text will use.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setTextColor ( float  r,
float  g,
float  b,
float  a 
)
virtual

Set the color of the polygon.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setBackgroundColor ( float  r,
float  g,
float  b,
float  a 
)
virtual

Set the color of the polygon.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setPosition ( int  vtx,
const DtVector position 
)
virtual

No longer sets the origin, in order to allow the moving of vtx0.

Reimplemented from makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setVertexList ( const vrvTacticalGraphicUtilities::DtVerticesVector verList)
virtual

Sets the vertex information using DtVectors.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::removePosition ( int  index)
virtual

Calls removePoint.

Reimplemented from makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setGroup ( int  )
virtual

The higher the Z order the "closer" to the eyepoint this element will be drawn. Use this variable to stack overlay objects in the particular order you want them displayed.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setOrientation ( int  vtx,
const DtTaitBryan &  orientation 
)
virtual

Set the orientation of a vertex of the polygon; has no effect.

Reimplemented from makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setIsSupportModel ( bool  isSupport)
virtual

Set whether the model is part of the support group (whether or not other scene objects can ground clamp to this model)

Implements makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setEventsEnabled ( bool  )
virtual

Sets whether or not mouse events are enabled.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setVisible ( bool  isVisible)
virtual

Sets whether or not the polygon is visible.

Reimplemented from makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::addToScene ( const DtUniqueID sceneObjectId,
DtModelSetId  modelSet,
int  visualizerType 
)
virtual

Add the polygon to the scene.

Implements makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::removeFromScene ( )
virtual

Remove the polygon from the scene.

Implements makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setModelDefinition ( const std::string &  str)
virtual

Sets the model definition on the model instance.

Reimplemented from makVrv::DtModel.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setIsClosedFigure ( bool  )
virtual

Whether or not the provided vertices represent a closed figure. Default is true.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setScreenIntervaledTextPrefixAndPostFixSeparator ( const std::string &  separatorString)
virtual

Set the separator string that will be applied after the prefix string and before the postfix string. The default is a newline.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setScreenIntervaledTextPrefix ( const std::string &  prefixString)
virtual

Set the prefix string that will be applied to all screen intervaled text, if rendered. The prefix string automatically has a newline appended to the end of it.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setScreenIntervaledTextPostfix ( const std::string &  postfixString)
virtual

Set the postfix string that will be applied to all screen intervaled text, if rendered. The postfix string automatically has a newline appended to the beginning of it.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setScreenIntervaledTextCollection ( const DtScreenIntervaledTextCollection )
virtual

Sets the collection of strings that will be rendered and wrapped around the perimeter of the polygon. The order they will be rendered in will depend on their order in the passed DtScreenIntervaledTextCollection.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setScreenIntervaledTextInterval ( int  intervalInScreenSpaceCM)
virtual

Set the interval, in centimeters of screen space, at which the screen intervaled text will appear at. If the perimeter of the polygon does not exceed: minimumScreenSpacePerimeterRequired = # of screen intervaled text strings * interval in CM) then, the screen intervaled text is not rendered at all.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::update ( )
protectedvirtual

Called on tick when updated, calls updateGeometry() of model instance.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::needsUpdate ( )
protectedvirtual

Sets needs update flag such that on next update pass the object is updated.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::slot_channelCreated ( DtChannel channel)
protectedvirtual

Called when channel is created, if the model set is this model set then add a new model instance.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::slot_channelDestroyed ( DtChannelManager channelManager,
DtChannel channel 
)
protectedvirtual

If the channel destroyed contains an instance of this model, destroy that model instance.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::setupInstanceWithCurrentValues ( DtOverlayScreenIntervaledTextInstance ,
const vrvTacticalGraphicUtilities::DtVerticesVector  
)
protectedvirtual

Sets up the model instance with current values of this model.

virtual void makVrv::DtOverlayScreenIntervaledTextModel::addedToSceneObject ( const DtUniqueID sceneObj,
DtModelSetId  modelSet,
int  visualizerType 
)
protectedvirtual

Called when a scene object added the model with the given model set and visualizer type.

Reimplemented from makVrv::DtModel.

Member Data Documentation

bool makVrv::DtOverlayScreenIntervaledTextModel::myEventsEnabled
protected
DtTaitBryan makVrv::DtOverlayScreenIntervaledTextModel::myRotation
protected
DtSignalConnectionManager makVrv::DtOverlayScreenIntervaledTextModel::myConnections
protected
vrvTacticalGraphicUtilities::DtVerticesVector makVrv::DtOverlayScreenIntervaledTextModel::myVertices
protected
DtScreenIntervaledTextCollection makVrv::DtOverlayScreenIntervaledTextModel::myScreenIntervaledTextCollection
protected

These are channel specific variables for perimeter text rendering They are not part of the model set instance.

int makVrv::DtOverlayScreenIntervaledTextModel::myScreenIntervaledTextIntervalInScreenSpaceCM
protected

These are channel specific variables for perimeter text rendering They are not part of the model set instance.

std::string makVrv::DtOverlayScreenIntervaledTextModel::myScreenIntervaledTextFontFile
protected

These are channel specific variables for perimeter text rendering They are not part of the model set instance.

float makVrv::DtOverlayScreenIntervaledTextModel::myScreenIntervaledTextFontPointSize
protected

These are channel specific variables for perimeter text rendering They are not part of the model set instance.

float makVrv::DtOverlayScreenIntervaledTextModel::myTextColor[4]
protected

These are channel specific variables for perimeter text rendering They are not part of the model set instance.

float makVrv::DtOverlayScreenIntervaledTextModel::myBackgroundColor[4]
protected

These are channel specific variables for perimeter text rendering They are not part of the model set instance.

std::string makVrv::DtOverlayScreenIntervaledTextModel::myScreenIntervaledTextPrefixPostfixSeparatorString
protected
std::string makVrv::DtOverlayScreenIntervaledTextModel::myScreenIntervaledTextPrefixString
protected
std::string makVrv::DtOverlayScreenIntervaledTextModel::myScreenIntervaledTextPostfixString
protected
ChannelInstances makVrv::DtOverlayScreenIntervaledTextModel::myChannelInstances
protected
bool makVrv::DtOverlayScreenIntervaledTextModel::myNeedsUpdate
protected
bool makVrv::DtOverlayScreenIntervaledTextModel::myIsClosedFigure
protected
std::string makVrv::DtOverlayScreenIntervaledTextModel::myModelDefinition
protected

Variables that are saved in order to switch between channel instance and model set instance.

int makVrv::DtOverlayScreenIntervaledTextModel::myGroup
protected

Variables that are saved in order to switch between channel instance and model set instance.


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

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)