![]() |
VR-Forces Developer's Guide
|
A model instance class which allows the drawing of a polygon (supporting textures) on an overlay. The polygon supports any combination of the of following:

Classes | |
| struct | DtPolygonWithInterfaces |
| struct | VertexData |
Public Types | |
| using | VertexList = std::vector< VertexData > |
Public Member Functions | |
| DtOverlayPolygonModelInstance (DtDe &de) | |
| virtual | ~DtOverlayPolygonModelInstance () |
| DtOverlayPolygonModelInstance ()=delete | |
| DtOverlayPolygonModelInstance (const DtOverlayPolygonModelInstance &)=delete | |
| DtOverlayPolygonModelInstance & | operator= (const DtOverlayPolygonModelInstance &)=delete |
| virtual void | setModelSet (DtModelSetId) |
| virtual void | setPosition (int vtx, const DtVector &position) |
| virtual void | setRotation (const DtQuat &quat) |
| virtual void | setOrigin (const DtVector &) |
| virtual void | setGroup (int) |
| virtual DtVector | origin () const |
| virtual void | addPoint (const DtVector &point, int index) |
| virtual void | removePoint (int index) |
| virtual void | set2dOffset (int index, float x, float y) |
| virtual void | set3dDirection2dLength (int index, float x, float y, float z, float len) |
| virtual void | setColor (float r, float g, float b, float a) |
| virtual void | setFillTexturePath (const std::string &texturePath, bool isStipple=true) |
| virtual void | setOutlineTexture (const std::string &texturePath, int width=-1, int height=-1) |
| virtual void | setSolidFillCenter (bool) |
| virtual void | setStipplePattern (unsigned int stipplePattern) |
| virtual void | setWidth (float width) |
| virtual void | setEventWidth (float width) |
| virtual void | setVisible (bool isVisible) |
| virtual void | setPickable (bool enabled) |
| virtual void | setEventsEnabled (bool, unsigned long long userData) |
| bool | eventsEnabled () const |
| virtual void | setFill (bool) |
| virtual void | setInsideColor (float r, float g, float b, float a) |
| virtual void | getInsideColor (float &r, float &g, float &b, float &a) |
| virtual void | setOutsideColor (float r, float g, float b, float a) |
| virtual void | getOutsideColor (float &r, float &g, float &b, float &a) |
| virtual int | pointCount () const |
| virtual DtVector | point (int) const |
| virtual void | setFillPattern (const std::vector< unsigned int > &pattern) |
| virtual void | setFillPatternFrequency (float frequency) |
| virtual float | fillPatternFrequency () const |
| virtual void | setOutline (bool) |
| virtual void | setEnableDecalProjector (bool enable) |
| virtual bool | enableDecalProjector () const |
| virtual void | setChannelInstance (DtChannel *, DtModelSetId modelSet) |
| virtual const VertexList & | vertexList () const |
| virtual void | setPoints (const std::vector< DtVector > &points) |
| virtual void | setVertexList (const VertexList &) |
| virtual const std::vector < DtVector > & | points () const |
| virtual void | updateGeometry () |
Public Member Functions inherited from makVrv::DtModelInstance | |
| DtModelInstance (DtDe &de) | |
| virtual | ~DtModelInstance () |
| virtual bool | realize (const DtModelDefinition &definition) |
| virtual bool | cloneInstance (const DtModelDefinition &definition) |
| const std::string & | realizedDefinitionName () const |
| virtual bool | saveModelToFile (const std::string &filename) const |
| const DtVector & | boundingBoxExtents () const |
| void | getBoundingBoxExtents (double &x, double &y, double &z) const |
| const DtVector & | boundingBoxCenter () const |
| void | getBoundingBoxCenter (double &x, double &y, double &z) const |
| void | getBoundingBoxComponents (DtVector &minimum, DtVector &maximum) |
| const DtVector & | allGeometryboundingBoxExtents () const |
| void | getAllGeometryBoundingBoxExtents (double &x, double &y, double &z) const |
| const DtVector & | allGeometryboundingBoxCenter () const |
| void | getAllGeometryBoundingBoxCenter (double &x, double &y, double &z) const |
| void | getAllGeometryBoundingBoxComponents (DtVector &minimum, DtVector &maximum) |
| virtual void | setContributesToBound (bool trueOrFalse) |
| bool | contributesToBound () const |
| virtual void | setBlendColor (float r, float g, float b, float a) |
| virtual void | enableColorBlending (bool b) |
Protected Member Functions | |
| virtual void | createPolygonIfNecessary () |
| virtual void | updateColors () |
| virtual void | computeTopoTransform (DtCoordTransform &geocToTopo, DtVector &geocentricOrigin) const |
| virtual void | updateTextureCoordinates (DtFilledPolygonInterface *polygon) |
| virtual void | translateAndUpdateVertex (unsigned int index, const VertexData &vert, DtPolygonInterface *polygon) |
| virtual void | channelUpdated (const DtTacticalGraphicModelUpdaterManager::ChannelUpdateData &) |
| virtual std::vector< DtVector > | topographicVertices () const |
| virtual void | slot_coordinateSystemChanged () |
| virtual void | deletePolygons () |
Additional Inherited Members | |
Static Public Member Functions inherited from makVrv::DtModelInstance | |
| static float | readFloat (const std::string ¶mName, const DtModelDefinition &definition) |
| static DtVector | readVector (const std::string ¶mName, const DtModelDefinition &definition) |
| static DtVector4< float > | readVector4 (const std::string ¶mName, const DtModelDefinition &definition) |
Public Attributes inherited from makVrv::DtModelInstance | |
| boost::signalslib::signal < void(DtModelInstance *)> | signal_modelInstanceChanged |
| using makVrv::DtOverlayPolygonModelInstance::VertexList = std::vector<VertexData> |
| makVrv::DtOverlayPolygonModelInstance::DtOverlayPolygonModelInstance | ( | DtDe & | de | ) |
CTOR.
|
virtual |
DTOR.
|
delete |
Default Constructor not implemented.
|
delete |
Copy Constructor not implemented - Copy not allowed.
|
delete |
Assignment Operator not implemented - Copy not allowed.
|
virtual |
Sets the model set this overlay item belongs to. Will clear out channelInstance if set.
|
virtual |
Set one of the endpoints of the Polygon.
|
virtual |
Set the rotation of the polygon.
|
virtual |
Sets the origin. Will update geometry.
|
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 |
Returns the origin.
|
virtual |
Add a new point to the polygon at the specified index, or, at the end if index is -1.
|
virtual |
Removes the point from the specified index.
|
virtual |
Sets the 2D offset of a vertex.
|
virtual |
Sets a 3D direction with a 2D length of a vertex. This only works with outline polygons.
|
virtual |
Set the color of the Polygon.
|
virtual |
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 |
Set the path to the polygon's outline texture as well as the tile size the texture will be scaled to.
| texturePath | The path to the polygon's outline texture |
| width | The width to scale to. If this argument or height are -1, no scaling is applied. |
| height | The height to scale to. If this argument or width are -1, no scaling is applied. |
|
virtual |
Sets to fill the center solid (if filled) not gradiant. Default is false.
|
virtual |
Sets stipple pattern for the polygon.
|
virtual |
Set the polygon outline width.
|
virtual |
Set the polygon outline width.
|
virtual |
Sets whether the model is visible or not.
Implements makVrv::DtModelInstance.
|
virtual |
Sets whether or not the polygon is pickable.
|
virtual |
Sets whether or not mouse events are enabled.
| bool makVrv::DtOverlayPolygonModelInstance::eventsEnabled | ( | ) | const |
Gets whether or not mouse events are enabled.
|
virtual |
Sets whether or not polygon is filled.
|
virtual |
Set the color at the center of the ellipse.
|
virtual |
Retrieves the inside color.
|
virtual |
Set the color on the outside of the ellipse.
|
virtual |
Retrieves the inside color.
|
virtual |
Retrieves the number of points in the model.
Retrieves the point.
|
virtual |
Sets fill pattern (32x32)
|
virtual |
Sets the fill pattern tiling frequency. The frequency needs to be 1 / x where x is a whole number. examples: frequency = 1.0 : the tiled pattern will tile normally frequency = 0.5 : the tiled pattern will appear half as often.
|
virtual |
Returns the fill pattern tiling frequency.
|
virtual |
Sets the fact that, if the object is filled, also provide an outline scribe. Basically create a filled and outline polygon.
|
virtual |
Set whether or not the geometry is used for a decal projector.
|
virtual |
Returns whether or not the geometry is used for a decal projector.
|
virtual |
Set to make this model channel specific. This means it will only update itself when the channel it is assigned to is updated. Enabled only to display on the channel/model set combination.
|
virtual |
Returns the vertex information for this polygon.
|
virtual |
Sets all the points for this polygon.
|
virtual |
Sets the vertex information for this polygon.
|
virtual |
Returns the list of vertices.
|
virtual |
Updates the vertex information into the polygon (if not locked)
|
protectedvirtual |
If not already created, creates the appropriate polygon (filled OR outlined) and perimeter wrapped text.
|
protectedvirtual |
Updates the colors of the object.
|
protectedvirtual |
Helper method to compute the current topo coordinate transform based on the current coordinate system and first vertex location.
|
protectedvirtual |
Updates the given polygon's texture coodinates using top-down texture projection.
|
protectedvirtual |
Sets a polygon vertex's position.
|
protectedvirtual |
Update texture information with zoom and orientation changes.
|
protectedvirtual |
Converts all vertices from local coordinates to topographic. Easier to use for triangulation.
|
protectedvirtual |
slot for when the coordinate system changes
|
protectedvirtual |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
local clone of the system wide coordinate system. for thread safety.