Tulip
4.6.0
Better Visualization Through Research
|
#include <GlRegularPolygon.h>
Public Member Functions | |
GlRegularPolygon (const Coord &position, const Size &size, unsigned int numberOfSides, const Color &outlineColor=Color(255, 0, 0, 255), const Color &fillColor=Color(0, 0, 255, 255), bool filled=true, bool outlined=true, const std::string &textureName="", float outlineSize=1.) | |
virtual | ~GlRegularPolygon () |
unsigned int | getNumberOfSides () |
void | resizePoints (const unsigned int number) |
void | setNumberOfSides (unsigned int number) |
void | setStartAngle (float angle) |
Protected Member Functions | |
void | computePolygon () |
Protected Attributes | |
unsigned int | numberOfSides |
Coord | position |
Size | size |
float | startAngle |
class to create a regular polygon
Definition at line 32 of file GlRegularPolygon.h.
tlp::GlRegularPolygon::GlRegularPolygon | ( | const Coord & | position, |
const Size & | size, | ||
unsigned int | numberOfSides, | ||
const Color & | outlineColor = Color(255, 0, 0, 255) , |
||
const Color & | fillColor = Color(0, 0, 255, 255) , |
||
bool | filled = true , |
||
bool | outlined = true , |
||
const std::string & | textureName = "" , |
||
float | outlineSize = 1. |
||
) |
Constructor.
The outline is the border of the regular polygon
The fill is inside the regular polygon
virtual tlp::GlRegularPolygon::~GlRegularPolygon | ( | ) | [virtual] |
Destructor.
unsigned int tlp::GlRegularPolygon::getNumberOfSides | ( | ) |
Get the number of Sides.
void tlp::GlRegularPolygon::resizePoints | ( | const unsigned int | number | ) | [virtual] |
Set the number of sides (use setNumberOfSides)
Reimplemented from tlp::GlPolygon.
void tlp::GlRegularPolygon::setNumberOfSides | ( | unsigned int | number | ) |
Set the number of sides.
void tlp::GlRegularPolygon::setStartAngle | ( | float | angle | ) |
Set the start angle in degree.
If the start angle is 0 : the regular polygon begin at the top middle point