VR-Forces 4.0.4 Class Documentation
Classes | Public Member Functions | Static Public Attributes | Protected Types | Protected Member Functions | Protected Attributes
makVrv::DtPolygonModelInstance Class Reference

Model instance to draw a polygon. More...

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

List of all members.

Classes

struct  AttachablePolygonParameters

Public Member Functions

 DtPolygonModelInstance (DtDe &de)
 CTOR.
virtual ~DtPolygonModelInstance ()
 DTOR.
virtual bool realize (DtModelDefinition &definition)
 Realize settings according to model definition.
virtual void setColor (float r, float g, float b, float a)
 Set the color of the Polygon.
virtual void setPosition (int vtx, const DtVector &position)
 Set one of the endpoints of the Polygon.
virtual void setTexturePath (const std::string &texturePath)
 Set the texture file path for the polygon.
virtual void setNumTextureTiles (double numTiles)
 Set the number of times to tile the texture.
virtual void setOrientation (int vtx, const DtTaitBryan &orientation)
 No-op.
virtual void addToConnector (DtOsgSceneConnector *connector)
 Tell the model instance to add itself to the provided node.
virtual bool removeFromConnector (DtOsgSceneConnector *connector)
 Tell the model instance to remove itself from the provided node.
virtual void setVisible (bool isVisible)
 no-op
virtual void addPoint (const DtVector &point, int index)
 Add a new point to the line at the specified index, or, at the end if index is -1.
virtual void setLockUpdates (bool lock)
 Will either update or batch updates until a future unlock is given.
bool updatesLocked () const
virtual void setPickable (bool enabled)
 Sets whether or not the line is pickable.
virtual void removePoint (int index)
 Removes the point from the specified index.
virtual void setStipplePattern (unsigned int stipplePattern)
 Sets stipple pattern for the polygon.
virtual void setWidth (float width)
 Set the line width.

Static Public Attributes

static const
AttachablePolygonParameters 
defaultParameters
 Default values for the polygon parameters.

Protected Types

typedef std::vector< osg::Vec3 > VertexList

Protected Member Functions

virtual void buildGeometry (const AttachablePolygonParameters &parameters)
 Build the Polygon's geometry from a parameter set.
virtual void buildState (const AttachablePolygonParameters &parameters)
 Build the Polygon's state from a parameter set.

Protected Attributes

osg::ref_ptr< osg::LineWidth > myLineWidth
AttachablePolygonParameters myParameters
 The current parameter set.
VertexList myVertices
osg::ref_ptr< osg::Geode > myGeode
bool myIsLocked
bool myGeometryIsDirty
bool myStateIsDirty

Detailed Description

Model instance to draw a polygon.


Member Typedef Documentation

typedef std::vector<osg::Vec3> makVrv::DtPolygonModelInstance::VertexList [protected]

Constructor & Destructor Documentation

CTOR.

DTOR.


Member Function Documentation

virtual bool makVrv::DtPolygonModelInstance::realize ( DtModelDefinition definition) [virtual]

Realize settings according to model definition.

Reimplemented from makVrv::DtModelInstance.

virtual void makVrv::DtPolygonModelInstance::setColor ( float  r,
float  g,
float  b,
float  a 
) [virtual]

Set the color of the Polygon.

virtual void makVrv::DtPolygonModelInstance::setPosition ( int  vtx,
const DtVector position 
) [virtual]

Set one of the endpoints of the Polygon.

virtual void makVrv::DtPolygonModelInstance::setTexturePath ( const std::string &  texturePath) [virtual]

Set the texture file path for the polygon.

The texture will be projected using the x-y coordinates of a topographic frame with the origin at some arbitrary point of the polygon.

virtual void makVrv::DtPolygonModelInstance::setNumTextureTiles ( double  numTiles) [virtual]

Set the number of times to tile the texture.

virtual void makVrv::DtPolygonModelInstance::setOrientation ( int  vtx,
const DtTaitBryan &  orientation 
) [virtual]

No-op.

Tell the model instance to add itself to the provided node.

Reimplemented from makVrv::DtOsgModelInstance.

Reimplemented in makVrv::DtMovablePolygonModel::DtMovablePolygonModelInstance.

Tell the model instance to remove itself from the provided node.

Reimplemented from makVrv::DtOsgModelInstance.

virtual void makVrv::DtPolygonModelInstance::setVisible ( bool  isVisible) [inline, virtual]

no-op

Implements makVrv::DtModelInstance.

virtual void makVrv::DtPolygonModelInstance::addPoint ( const DtVector point,
int  index 
) [virtual]

Add a new point to the line at the specified index, or, at the end if index is -1.

virtual void makVrv::DtPolygonModelInstance::setLockUpdates ( bool  lock) [virtual]

Will either update or batch updates until a future unlock is given.

virtual void makVrv::DtPolygonModelInstance::setPickable ( bool  enabled) [virtual]

Sets whether or not the line is pickable.

virtual void makVrv::DtPolygonModelInstance::removePoint ( int  index) [virtual]

Removes the point from the specified index.

virtual void makVrv::DtPolygonModelInstance::setStipplePattern ( unsigned int  stipplePattern) [virtual]

Sets stipple pattern for the polygon.

virtual void makVrv::DtPolygonModelInstance::setWidth ( float  width) [virtual]

Set the line width.

virtual void makVrv::DtPolygonModelInstance::buildGeometry ( const AttachablePolygonParameters parameters) [protected, virtual]

Build the Polygon's geometry from a parameter set.

virtual void makVrv::DtPolygonModelInstance::buildState ( const AttachablePolygonParameters parameters) [protected, virtual]

Build the Polygon's state from a parameter set.


Member Data Documentation

Default values for the polygon parameters.

osg::ref_ptr<osg::LineWidth> makVrv::DtPolygonModelInstance::myLineWidth [protected]

The current parameter set.

osg::ref_ptr<osg::Geode> makVrv::DtPolygonModelInstance::myGeode [protected]

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

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)