Tulip  4.4.0
Better Visualization Through Research
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Groups Pages
tlp::GlStar Class Reference

#include <GlStar.h>

Inherits tlp::GlComplexPolygon.

Public Member Functions

 GlStar (const Coord &position, const Size &size, unsigned int numberOfStarPoints, const Color &fillColor=Color(0, 0, 255), const Color &outlineColor=Color(0, 0, 0), bool outlined=true, const std::string &textureName="", float outlineSize=1.)
 
virtual ~GlStar ()
 
unsigned int getNumberOfStarPoints ()
 
- Public Member Functions inherited from tlp::GlComplexPolygon
 GlComplexPolygon ()
 
 GlComplexPolygon (const std::vector< Coord > &coords, Color fcolor, int polygonEdgesType=0, const std::string &textureName="")
 
 GlComplexPolygon (const std::vector< Coord > &coords, Color fcolor, Color ocolor, int polygonEdgesType=0, const std::string &textureName="")
 
 GlComplexPolygon (const std::vector< std::vector< Coord > > &coords, Color fcolor, int polygonEdgesType=0, const std::string &textureName="")
 
 GlComplexPolygon (const std::vector< std::vector< Coord > > &coords, Color fcolor, Color ocolor, int polygonEdgesType=0, const std::string &textureName="")
 
void activateQuadBorder (const float borderWidth, const Color &color, const std::string &texture="", const int position=1, const float texCoordFactor=1.f, const int polygonId=0)
 
void desactivateQuadBorder (const int polygonId=0)
 
virtual void draw (float lod, Camera *camera)
 
Color getFillColor () const
 
Color getOutlineColor () const
 
const std::vector< std::vector
< Coord > > & 
getPolygonSides () const
 
std::string getTextureName ()
 
float getTextureZoom ()
 
virtual void getXML (std::string &outString)
 
virtual void getXMLOnlyData (std::string &outString)
 
QStringList propertiesNames () const
 
QVariantList propertiesQVariant () const
 
void setFillColor (const Color &color)
 
void setOutlineColor (const Color &color)
 
void setOutlineMode (const bool)
 
void setOutlineSize (double size)
 
void setProperty (const QString &name, const QVariant &value)
 
void setTextureName (const std::string &name)
 
void setTextureZoom (float zoom)
 
virtual void setWithXML (const std::string &inString, unsigned int &currentPosition)
 
virtual void translate (const Coord &mouvement)
 
- Public Member Functions inherited from tlp::GlSimpleEntity
 GlSimpleEntity ()
 
virtual ~GlSimpleEntity ()
 
virtual BoundingBox getBoundingBox ()
 
int getStencil ()
 
bool isVisible () const
 
virtual void setStencil (int stencil)
 
virtual void setVisible (bool visible)
 

Protected Member Functions

void computeStar ()
 
- Protected Member Functions inherited from tlp::GlComplexPolygon
virtual void addPoint (const Coord &point)
 
void addVertex (const Coord &vertexCoord, const Vec2f &vertexTexCoord)
 
VERTEX * allocateNewVertex ()
 
virtual void beginNewHole ()
 
void createPolygon (const std::vector< Coord > &coords, int polygonEdgesType)
 
void endPrimitive ()
 
void runTesselation ()
 
void startPrimitive (GLenum primitive)
 

Protected Attributes

unsigned int numberOfStarPoints
 
Coord position
 
Size size
 
- Protected Attributes inherited from tlp::GlComplexPolygon
std::vector< VERTEX * > allocatedVertices
 
GLenum currentPrimitive
 
int currentVector
 
Color fillColor
 
int nbPrimitiveVertices
 
Color outlineColor
 
bool outlined
 
double outlineSize
 
std::vector< std::vector< Coord > > points
 
std::vector< std::vector
< GLfloat > > 
pointsIdx
 
std::set< GLenum > primitivesSet
 
std::vector< bool > quadBorderActivated
 
std::vector< Color > quadBorderColor
 
std::vector< int > quadBorderPosition
 
std::vector< float > quadBorderTexFactor
 
std::vector< std::string > quadBorderTexture
 
std::vector< float > quadBorderWidth
 
std::map< GLenum, std::vector
< int > > 
startIndicesMap
 
std::map< GLenum, std::vector
< Vec2f > > 
texCoordsMap
 
std::string textureName
 
float textureZoom
 
std::map< GLenum, std::vector
< int > > 
verticesCountMap
 
std::map< GLenum, std::vector
< Coord > > 
verticesMap
 
- Protected Attributes inherited from tlp::GlSimpleEntity
BoundingBox boundingBox
 
std::vector< GlComposite * > parents
 
int stencil
 
bool visible
 

Detailed Description

class to create a star

Definition at line 32 of file GlStar.h.

Constructor & Destructor Documentation

tlp::GlStar::GlStar ( const Coord &  position,
const Size &  size,
unsigned int  numberOfStarPoints,
const Color &  fillColor = Color(0, 0, 255),
const Color &  outlineColor = Color(0, 0, 0),
bool  outlined = true,
const std::string &  textureName = "",
float  outlineSize = 1. 
)

Constructor.

The outline is the border of the regular star

The fill is inside the regular star

virtual tlp::GlStar::~GlStar ( )
virtual

Destructor.

Member Function Documentation

unsigned int tlp::GlStar::getNumberOfStarPoints ( )

Get the number of star points.