![]() |
VR-Vantage API Documentation
|
The class definition for DtSdcArea3DObject, which represents an area object positioned in the 3D scene. More...

Public Member Functions | |
| DtSdcArea3DObject (DtExerciseConn *exConn, unsigned id, std::vector< DtVector > vertices, DtVector offset=DtVector::zero(), DtSdcColor color=DtSdcColor::DtSdcWhite, const DtString &textureDirectory="", const DtString &textureFilename=DtString::nullString(), int numTextureTiles=0, bool flashing=false) | |
| Construct the area Draw Control Object. | |
| virtual | ~DtSdcArea3DObject () |
| virtual const DtVector & | offset () const |
| offset accessor | |
| virtual void | setOffset (const DtVector &off) |
| offset mutator | |
| virtual const DtSdcColor & | color () const |
| color accessor | |
| virtual void | setColor (const DtSdcColor &color) |
| color mutator | |
| virtual bool | flashing () const |
| flashing accessor | |
| virtual void | setFlashing (bool flashing) |
| flashing mutator | |
| virtual const DtString & | textureDirectory () const |
| Texture directory accessor. | |
| virtual void | setTextureDirectory (const DtString &str) |
| Texture directory mutator. | |
| virtual const DtString & | textureFilename () const |
| Texture file name accessor. | |
| virtual void | setTextureFilename (const DtString &str) |
| Texture file name mutator. | |
| virtual int | numTextureTiles () const |
| Texture tile repetitions accessor. | |
| virtual void | setNumTextureTiles (int numTextureTiles) |
| Texture tile repetitions mutator. | |
| virtual void | update () |
| update the internal pdu | |
| virtual const DtVector & | vertex (int index) const |
| vertex accessor | |
| virtual void | setVertex (int index, const DtVector &vertex) |
| vertex mutator | |
| virtual void | setRemoteGraphicSet (const std::string &setName) |
Public Member Functions inherited from DtSdcObject | |
| DtSdcObject (DtExerciseConn *exConn, unsigned id, const DtString &objName) | |
| Parameterized constructor. | |
| virtual | ~DtSdcObject () |
| Virtual destructor. | |
| virtual unsigned | id () const |
| id accessor | |
| virtual void | setId (unsigned id) |
| id mutator | |
| virtual const DtGlobalObjectDesignator & | globalId () const |
| virtual void | setVisible (bool yesNo) |
| virtual bool | visible () const |
Protected Member Functions | |
| virtual void | calculateBoundingSphere () |
| virtual void | setStateRecordUserData () |
| void | initRecords () |
Protected Attributes | |
| DtVector | myOffset |
| DtSdcColor | myColor |
| bool | myFlashing |
| int | myNumVertices |
| std::vector< DtVector > | myVertices |
| DtString | myTextureFilename |
| DtString | myTextureDirectory |
| int | myNumTextureTiles |
| std::vector < DtEnvironmentalPointRecord > | myPointRecords |
| DtEnvironmentalBoundingSphereRecord | myBoundingSphereRecord |
| Dt3DGraphicalObjectStateRecord | myStateRecord |
| DtVector | myEmptyVertex |
Protected Attributes inherited from DtSdcObject | |
| unsigned | myId |
| DtEnvironmentProcessPublisher | myPublisher |
| bool | myVisible |
| DtSdcColor | myEmptyColor |
Private Member Functions | |
| DtSdcArea3DObject () | |
| Default constructor. | |
| DtSdcArea3DObject (const DtSdcArea3DObject &orig) | |
| Copy constructor. | |
| DtSdcArea3DObject & | operator= (const DtSdcArea3DObject &rhs) |
| Assignment operator. | |
The class definition for DtSdcArea3DObject, which represents an area object positioned in the 3D scene.
Currently, there are some limitations for an area to appear correctly; it should be a convex polygon, and its points should be specified in counter-clockwise order. The points should also all be coplanar. Polygons are currently limited to no more than 16 points. A 3D Area Stealth Draw Control Object.
DtSdcArea3DObject represents a area that can be positioned and displayed in the 3D scene. A color may be specified; and the area can flash, if desired; it can have a texture which may be tiled on the area (level of tiling controlled by setNumTextureTiles). Currently, there are some limitations for an area to appear correctly; it should be a convex polygon with no more than 16 vertices, and its points should be specified in counter-clockwise order. The points should also be coplanar.
| DtSdcArea3DObject::DtSdcArea3DObject | ( | DtExerciseConn * | exConn, |
| unsigned | id, | ||
| std::vector< DtVector > | vertices, | ||
| DtVector | offset = DtVector::zero(), |
||
| DtSdcColor | color = DtSdcColor::DtSdcWhite, |
||
| const DtString & | textureDirectory = "", |
||
| const DtString & | textureFilename = DtString::nullString(), |
||
| int | numTextureTiles = 0, |
||
| bool | flashing = false |
||
| ) |
Construct the area Draw Control Object.
| id | Passed to DtSdcObject base (see) |
| vertices | A std::list of DtVector's containing the vertices The color to apply to all segments constructed |
| flashing | A boolean parameter indicating whether or not the area should be flashing |
References Dt3DGraphicalObjectCategoryArea, Dt3DGraphicalObjectKind, DtSdcObject::id(), initRecords(), and DtSdcObject::myPublisher.
|
virtual |
|
private |
Default constructor.
Private and not implemented - you must supply an id and basic geometric parameters to construct the area
|
private |
Copy constructor.
Private and unimplemented - not copyable.
|
private |
Assignment operator.
Private and unimplemented - not copyable.
|
virtual |
offset accessor
Get the object's offset from the attach point, in entity coordinates if attached, geocentric otherwise
References myOffset.
Referenced by setOffset().
|
virtual |
offset mutator
Set the object's offset from the attach point, in entity coordinates if attached, geocentric otherwise
| enuOffset | [X, Y, Z] |
References myOffset, myStateRecord, offset(), and Dt3DGraphicalObjectStateRecord::setOffset().
|
virtual |
color accessor
Get the color assigned to the indicated segment
| segment | The segment to retrieve the color from |
Reimplemented from DtSdcObject.
References myColor.
Referenced by setColor().
|
virtual |
color mutator
Set the color to use when drawing the indicated segment
| color | The DtSdcColor to use |
| segment | The segment to apply the color to |
Reimplemented from DtSdcObject.
References DtSdcColor::alpha(), DtSdcColor::blue(), color(), DtSdcColor::green(), myColor, myStateRecord, DtSdcColor::red(), and Dt3DGraphicalObjectStateRecord::setColor().
|
virtual |
flashing accessor
Get the boolean that indicates whether or not the area should flash
Reimplemented from DtSdcObject.
References myFlashing.
Referenced by setFlashing().
|
virtual |
flashing mutator
Set the boolean that indicates whether or not the area should flash
| flashing | true or false |
Reimplemented from DtSdcObject.
References flashing(), myFlashing, myStateRecord, and Dt3DGraphicalObjectStateRecord::setFlashing().
|
virtual |
Texture directory accessor.
Get the directory for texture access
References myTextureDirectory.
|
virtual |
Texture directory mutator.
Set the directory for texture access
| str | directory name |
References myTextureDirectory, and setStateRecordUserData().
|
virtual |
Texture file name accessor.
Get the area's texture file name
References myTextureFilename.
|
virtual |
Texture file name mutator.
Set the area's texture file name
| str | name (without directory) of texture file |
References myTextureFilename, and setStateRecordUserData().
|
virtual |
Texture tile repetitions accessor.
Get the number of times texture repeats
References myNumTextureTiles.
Referenced by setNumTextureTiles().
|
virtual |
Texture tile repetitions mutator.
Set the int that indicates how many times texture repeats
| numTextureTiles | number of times texture repeats |
References myNumTextureTiles, numTextureTiles(), and setStateRecordUserData().
|
virtual |
update the internal pdu
Make sure the internal pdu reflects the actual state of the draw control object's members. This is necessary because some members can be modified directly (which make the interface easier to use). DtStealthRemoteDrawer::update() calls this, so the user doesn't need to; but if the user is accessing the pdu directly (via the pdu() accessor) this should be called before using the pdu.
Implements DtSdcObject.
References myBoundingSphereRecord, myPointRecords, DtSdcObject::myPublisher, myStateRecord, and myVertices.
|
virtual |
vertex accessor
Get the vertex at index (0-indexed) Vertices should be specified in counterclockwise order and should define a convex polygon.
| index,from | 0 to 15 |
References myEmptyVertex, myNumVertices, and myVertices.
|
virtual |
vertex mutator
Set the area's vertex at index (0-indexed) Vertices should be specified in counterclockwise order and should define a convex polygon.
| index | (from 0 to 15) vertex (in geocentric coordinates) |
References calculateBoundingSphere(), myNumVertices, myPointRecords, and myVertices.
|
virtual |
Reimplemented from DtSdcObject.
References myStateRecord, Dt3DGraphicalObjectStateRecord::setNumberOfParentOverlays(), and Dt3DGraphicalObjectStateRecord::setParentOverlay().
|
protectedvirtual |
References vrvControlToolkit::DtDistance(), myBoundingSphereRecord, and myVertices.
Referenced by initRecords(), and setVertex().
|
protectedvirtual |
References myNumTextureTiles, myStateRecord, myTextureDirectory, myTextureFilename, and Dt3DGraphicalObjectStateRecord::setUserData().
Referenced by initRecords(), setNumTextureTiles(), setTextureDirectory(), and setTextureFilename().
|
protected |
References DtSdcColor::alpha(), DtSdcColor::blue(), calculateBoundingSphere(), DtSdcColor::green(), myColor, myFlashing, myOffset, myPointRecords, myStateRecord, myVertices, DtSdcColor::red(), Dt3DGraphicalObjectStateRecord::setColor(), Dt3DGraphicalObjectStateRecord::setFlashing(), Dt3DGraphicalObjectStateRecord::setOffset(), and setStateRecordUserData().
Referenced by DtSdcArea3DObject(), and DtSdcTriangle3DObject::DtSdcTriangle3DObject().
|
protected |
Referenced by initRecords(), offset(), and setOffset().
|
protected |
Referenced by color(), initRecords(), and setColor().
|
protected |
Referenced by flashing(), initRecords(), and setFlashing().
|
protected |
Referenced by setVertex(), and vertex().
|
protected |
Referenced by calculateBoundingSphere(), DtSdcTriangle3DObject::DtSdcTriangle3DObject(), initRecords(), setVertex(), DtSdcTriangle3DObject::setVertex1(), DtSdcTriangle3DObject::setVertex2(), DtSdcTriangle3DObject::setVertex3(), update(), vertex(), DtSdcTriangle3DObject::vertex1(), DtSdcTriangle3DObject::vertex2(), and DtSdcTriangle3DObject::vertex3().
|
protected |
Referenced by setStateRecordUserData(), setTextureFilename(), and textureFilename().
|
protected |
Referenced by setStateRecordUserData(), setTextureDirectory(), and textureDirectory().
|
protected |
Referenced by numTextureTiles(), setNumTextureTiles(), and setStateRecordUserData().
|
protected |
|
protected |
Referenced by calculateBoundingSphere(), and update().
|
protected |
Referenced by initRecords(), setColor(), setFlashing(), setOffset(), setRemoteGraphicSet(), setStateRecordUserData(), and update().
|
protected |
Referenced by vertex().