![]() |
VR-Forces 4.0.4 Class Documentation
|
A convex polygon drawn using lines. More...

Public Member Functions | |
| DtOutlinedPolygon (DtOverlayRenderer &renderer, DtWidgetPicker &picker) | |
| CTOR. | |
| DtOutlinedPolygon (DtLineRenderer &renderer, DtWidgetPicker &picker) | |
| CTOR. | |
| virtual | ~DtOutlinedPolygon () |
| DTOR. | |
| virtual void | setEventsEnabled (bool enabled, unsigned long long userData=0) |
| Set whether the sprite has widget events. | |
| bool | eventsEnabled () const |
| Get whether events are already enabled. | |
| virtual void | setVertexCount (unsigned int vertexCount) |
| Set the number of vertices, set the number of vertices before setting their parameters (position, color etc). | |
| virtual unsigned int | vertexCount () const |
| Get the vertex count. | |
| virtual void | set2DPositions (const std::vector< float > &vertices) |
| Set the number of vertices and their positions. | |
| virtual void | set2DPosition (unsigned int vertexIndex, float x1, float y1) |
| Set the vertex positions. | |
| virtual void | get2DPosition (unsigned int vertexIndex, float &x, float &y) const |
| Get the vertex position. | |
| virtual void | set3DPosition (unsigned int vertexIndex, float x, float y, float z, float w) |
| Set one vertex position. | |
| virtual void | get3DPosition (unsigned int vertexIndex, float &x, float &y, float &z, float &w) const |
| Get the vertex position. | |
| virtual void | set3DDirectionAndLength (unsigned int index, float x, float y, float z, float l) |
| Sets an optional 3D direction with a 2D length value for a vertex. | |
| virtual void | setVertexColor (unsigned int index, float r, float g, float b, float a) |
| Set the color of a specific vertex. | |
| virtual void | getVertexColor (unsigned int index, float &r, float &g, float &b, float &a) |
| Get the color of a specific vertex. | |
| virtual void | setColor (float r, float g, float b, float a) |
| Set entire poly-line color. | |
| virtual void | getColor (float &r, float &g, float &b, float &a) const |
| Get the poly-line color. | |
| void | setStippleParameters (unsigned int scale, unsigned short pattern) |
| Set the entire poly-line stipple. | |
| virtual void | setStipple (unsigned int stipplePattern) |
| Set the stipple pattern. | |
| virtual void | setOutlineWidth (float) |
| Sets the width of the line segments that comprise the polygon. | |
| virtual void | setEventOutlineWidth (float) |
| Sets the width of the event outline segments. | |
Protected Types | |
| typedef std::vector < DtLineSegment * > | LineSegmentList |
| typedef std::vector < DtPickableLine * > | PickableSegmentList |
Protected Attributes | |
| DtLineRenderer & | myRenderer |
| DtWidgetPicker & | myPicker |
| LineSegmentList | myLineSegments |
| PickableSegmentList | myPickableSegments |
| bool | myEventsEnabled |
| unsigned long long | myUserData |
| float | myWidth |
| float | myEventWidth |
A convex polygon drawn using lines.
typedef std::vector<DtLineSegment*> makVrv::DtOutlinedPolygon::LineSegmentList [protected] |
typedef std::vector<DtPickableLine*> makVrv::DtOutlinedPolygon::PickableSegmentList [protected] |
| makVrv::DtOutlinedPolygon::DtOutlinedPolygon | ( | DtOverlayRenderer & | renderer, |
| DtWidgetPicker & | picker | ||
| ) |
CTOR.
| makVrv::DtOutlinedPolygon::DtOutlinedPolygon | ( | DtLineRenderer & | renderer, |
| DtWidgetPicker & | picker | ||
| ) |
CTOR.
| virtual makVrv::DtOutlinedPolygon::~DtOutlinedPolygon | ( | ) | [virtual] |
DTOR.
| virtual void makVrv::DtOutlinedPolygon::setEventsEnabled | ( | bool | enabled, |
| unsigned long long | userData = 0 |
||
| ) | [virtual] |
Set whether the sprite has widget events.
Disabling events disconnects all of the DtOutlinedPolygon signals The user data is set when enabling the events, to change only the user data make multiple calls with enabled=true
Implements makVrv::DtPolygon.
| bool makVrv::DtOutlinedPolygon::eventsEnabled | ( | ) | const |
Get whether events are already enabled.
| virtual void makVrv::DtOutlinedPolygon::setVertexCount | ( | unsigned int | vertexCount | ) | [virtual] |
Set the number of vertices, set the number of vertices before setting their parameters (position, color etc).
Implements makVrv::DtPolygon.
| virtual unsigned int makVrv::DtOutlinedPolygon::vertexCount | ( | ) | const [virtual] |
Get the vertex count.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::set2DPositions | ( | const std::vector< float > & | vertices | ) | [virtual] |
Set the number of vertices and their positions.
vertices must be x,y,z encoded triplets.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::set2DPosition | ( | unsigned int | vertexIndex, |
| float | x1, | ||
| float | y1 | ||
| ) | [virtual] |
Set the vertex positions.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::get2DPosition | ( | unsigned int | vertexIndex, |
| float & | x, | ||
| float & | y | ||
| ) | const [virtual] |
Get the vertex position.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::set3DPosition | ( | unsigned int | vertexIndex, |
| float | x, | ||
| float | y, | ||
| float | z, | ||
| float | w | ||
| ) | [virtual] |
Set one vertex position.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::get3DPosition | ( | unsigned int | vertexIndex, |
| float & | x, | ||
| float & | y, | ||
| float & | z, | ||
| float & | w | ||
| ) | const [virtual] |
Get the vertex position.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::set3DDirectionAndLength | ( | unsigned int | index, |
| float | x, | ||
| float | y, | ||
| float | z, | ||
| float | l | ||
| ) | [virtual] |
Sets an optional 3D direction with a 2D length value for a vertex.
| index | the index of the vertex to get the position of |
| x | x component of the position |
| y | y component of the position |
| z | z component of the position |
| l | l length of the vector offset in 2D. |
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::setVertexColor | ( | unsigned int | index, |
| float | r, | ||
| float | g, | ||
| float | b, | ||
| float | a | ||
| ) | [virtual] |
Set the color of a specific vertex.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::getVertexColor | ( | unsigned int | index, |
| float & | r, | ||
| float & | g, | ||
| float & | b, | ||
| float & | a | ||
| ) | [virtual] |
Get the color of a specific vertex.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::setColor | ( | float | r, |
| float | g, | ||
| float | b, | ||
| float | a | ||
| ) | [virtual] |
Set entire poly-line color.
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::getColor | ( | float & | r, |
| float & | g, | ||
| float & | b, | ||
| float & | a | ||
| ) | const [virtual] |
Get the poly-line color.
Implements makVrv::DtPolygon.
| void makVrv::DtOutlinedPolygon::setStippleParameters | ( | unsigned int | scale, |
| unsigned short | pattern | ||
| ) |
Set the entire poly-line stipple.
Scale is from 1-256. Pattern is 16 bit mask. Warning Stippled lines are rendered significantly slower than non-Stippled lines. Setting the pattern to NoStipple causes the line not to be stippled anymore.
| virtual void makVrv::DtOutlinedPolygon::setStipple | ( | unsigned int | stipplePattern | ) | [virtual] |
Set the stipple pattern.
This pattern is used as a bitmask against the pixels of the polygon The default value is 0xFFFFFFFF, which is equivalent to no stippling
Implements makVrv::DtPolygon.
| virtual void makVrv::DtOutlinedPolygon::setOutlineWidth | ( | float | ) | [virtual] |
Sets the width of the line segments that comprise the polygon.
| virtual void makVrv::DtOutlinedPolygon::setEventOutlineWidth | ( | float | ) | [virtual] |
Sets the width of the event outline segments.
To use the outline width as the event width set the event outline width to -1.0f;
DtLineRenderer& makVrv::DtOutlinedPolygon::myRenderer [protected] |
DtWidgetPicker& makVrv::DtOutlinedPolygon::myPicker [protected] |
bool makVrv::DtOutlinedPolygon::myEventsEnabled [protected] |
unsigned long long makVrv::DtOutlinedPolygon::myUserData [protected] |
float makVrv::DtOutlinedPolygon::myWidth [protected] |
float makVrv::DtOutlinedPolygon::myEventWidth [protected] |