| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
tlp::GlPolyQuad Class Reference
|
tlp::GlPolyQuad::GlPolyQuad | ( | const std::string & | textureName = "" , |
|
const bool | outlined = false , |
|||
const int | outlineWidth = 1 , |
|||
const Color & | outlineColor = Color(0, 0, 0) | |||
) |
Default Constructor for initializing an empty polyquad Use the addQuadEdge method to set the quads edges
textureName | The absolute path of the texture image file to use |
tlp::GlPolyQuad::GlPolyQuad | ( | const std::vector< Coord > & | polyQuadEdges, | |
const std::vector< Color > & | polyQuadEdgesColor, | |||
const std::string & | textureName = "" , |
|||
const bool | outlined = false , |
|||
const int | outlineWidth = 1 , |
|||
const Color & | outlineColor = Color(0, 0, 0) | |||
) |
Constructor for building a polyquad with spefific colors for each edges
Pay attention to the order of the edges point in the polyQuadEdges vector. Indeed, to draw the following polyquad
v2 v0+--------+--------+ v4 | | | | | | | | | v1+--------+--------+ v5 v3
The content of the polyQuadEdges vector should be {v0, v1, v2, v3, v4, v5} or {v1, v0, v3, v2, v5, v4}
polyQuadEdges | A vector containing the coordinates of the quad edges, its size must be a multiple of 2 because an edge is defined by 2 points | |
polyQuadEdgesColor | A vector containing the edges's colors, its size must be equal to the number of edges defined by the polyQuadEdges vector | |
textureName | The absolute path of the texture image file to use |
tlp::GlPolyQuad::GlPolyQuad | ( | const std::vector< Coord > & | polyQuadEdges, | |
const Color & | polyQuadColor, | |||
const std::string & | textureName = "" , |
|||
const bool | outlined = false , |
|||
const int | outlineWidth = 1 , |
|||
const Color & | outlineColor = Color(0, 0, 0) | |||
) |
Constructor for building a polyquad with a single color
polyQuadEdges | A vector containing the coordinates of the quad edges, its size must be a multiple of 2 because an edge is defined by 2 points | |
polyQuadColor | The polyquad color | |
textureName | The absolute path of the texture image file to use |
void tlp::GlPolyQuad::addQuadEdge | ( | const Coord & | edgeStart, | |
const Coord & | edgeEnd, | |||
const Color & | edgeColor | |||
) |
Method to add a polyquad edge
edgeStart | The first end of the edge | |
edgeEnd | The other end of the edge | |
edgeColor | The edge's color |
void tlp::GlPolyQuad::draw | ( | float | lod, | |
Camera * | camera | |||
) | [virtual] |
Virtual function used to draw the polyquad.
Implements tlp::GlSimpleEntity.
void tlp::GlPolyQuad::getXML | ( | xmlNodePtr | rootNode | ) | [virtual] |
Function to export data in XML
Implements tlp::GlSimpleEntity.
void tlp::GlPolyQuad::setColor | ( | const Color & | color | ) |
Method to set the polyquad color (all edges share the same color)
void tlp::GlPolyQuad::setOutlineColor | ( | const Color & | color | ) | [inline] |
Method to set the polyquad outline color
void tlp::GlPolyQuad::setOutlined | ( | const bool | outline | ) | [inline] |
Method to toggle polyquad outline
void tlp::GlPolyQuad::setOutlineWidth | ( | const int | width | ) | [inline] |
Method to set the polyquad outline width
void tlp::GlPolyQuad::setWithXML | ( | xmlNodePtr | rootNode | ) | [virtual] |
Function to set data with XML
Implements tlp::GlSimpleEntity.
void tlp::GlPolyQuad::translate | ( | const Coord & | move | ) | [virtual] |
Method to translate entity
Reimplemented from tlp::GlSimpleEntity.
Tulip Software by LaBRI Visualization Team 2001 - 2012 |