Overview     Modules     Class Hierarchy     Classes     Members  
tlp::GlRect Class Reference

This is a general class for the rendering of 2D rectangles. More...

#include <GlRect.h>

Inheritance diagram for tlp::GlRect:
Collaboration diagram for tlp::GlRect:

List of all members.

Public Member Functions

 GlRect (const Coord &topLeftPos, const Coord &bottomRightPos, const Color &topLeftCol, const Color &bottomRightCol, bool filled=true, bool outlined=false)
 GlRect (const Coord &center, const Size &size, const Color &fillColor, const Color &outlineColor)
 GlRect (bool filled=true, bool outlined=false)
virtual ~GlRect ()
virtual Coord getCenter ()
void setCenterAndSize (const Coord &center, const Size &size)
virtual Coord getTopLeftPos ()
virtual Coord getBottomRightPos ()
virtual Color getTopLeftColor ()
virtual Color getBottomRightColor ()
virtual void setTopLeftPos (const Coord &topLeftPos)
virtual void setBottomRightPos (const Coord &bottomRightPos)
virtual void setTopLeftColor (const Color &topLeftCol)
virtual void setBottomRightColor (const Color &bottomRightCol)
bool inRect (double x, double y)
virtual void getXML (xmlNodePtr rootNode)
virtual void setWithXML (xmlNodePtr rootNode)
virtual void draw (float lod, Camera *camera)
- Public Member Functions inherited from tlp::GlPolygon
 GlPolygon (const bool filled=true, const bool outlined=true, const std::string &textureName="", const float outlineSize=1)
 GlPolygon (const std::vector< Coord > &points, const std::vector< Color > &fillColors, const std::vector< Color > &outlineColors, const bool filled, const bool outlined, const std::string &textureName="", const float outlineSize=1)
 GlPolygon (const unsigned int nbPoints, const unsigned int nbFillColors, const unsigned int nbOutlineColors, const bool filled=true, const bool outlined=true, const std::string &textureName="", const float outlineSize=1)
virtual ~GlPolygon ()
virtual void resizePoints (const unsigned int nbPoints)
virtual void resizeColors (const unsigned int nbColors)
virtual const Coord & point (const unsigned int i) const
virtual Coord & point (const unsigned int i)
- Public Member Functions inherited from tlp::GlAbstractPolygon
 GlAbstractPolygon ()
virtual ~GlAbstractPolygon ()
PolygonMode getPolygonMode ()
void setPolygonMode (PolygonMode mode)
bool getFillMode ()
void setFillMode (const bool)
bool getOutlineMode ()
void setOutlineMode (const bool)
bool getLightingMode ()
void setLightingMode (const bool)
Color getFillColor (unsigned int i)
void setFillColor (unsigned int i, const Color &color)
void setFillColor (const Color &color)
Color getOutlineColor (unsigned int i)
void setOutlineColor (unsigned int i, const Color &color)
void setOutlineColor (const Color &color)
std::string getTextureName ()
void setTextureName (const std::string &name)
float getOutlineSize ()
void setOutlineSize (float size)
float getHideOutlineLod ()
void setHideOutlineLod (float lod)
virtual void translate (const Coord &mouvement)
virtual void getXMLOnlyData (xmlNodePtr rootNode)
const Color & fcolor (const unsigned int i) const
Color & fcolor (const unsigned int i)
void setFColor (const unsigned int i, const Color &color)
const Color & ocolor (const unsigned int i) const
virtual Color & ocolor (const unsigned int i)
virtual void setOColor (const unsigned int i, const Color &color)
- Public Member Functions inherited from tlp::GlSimpleEntity
 GlSimpleEntity ()
virtual ~GlSimpleEntity ()
virtual void acceptVisitor (GlSceneVisitor *visitor)
virtual void setVisible (bool visible)
bool isVisible ()
virtual void setStencil (int stencil)
int getStencil ()
void setCheckByBoundingBoxVisitor (bool check)
bool isCheckByBoundingBoxVisitor ()
virtual BoundingBox getBoundingBox ()
virtual void addLayerParent (GlLayer *)
virtual void removeLayerParent (GlLayer *)
void addParent (GlComposite *composite)
void removeParent (GlComposite *composite)
- Public Member Functions inherited from tlp::GlEntity
virtual ~GlEntity ()

Detailed Description

This is a general class for the rendering of 2D rectangles.

This class is used as a 2D HUD for the rendering of 2D rectangles.


Constructor & Destructor Documentation

tlp::GlRect::GlRect ( const Coord &  topLeftPos,
const Coord &  bottomRightPos,
const Color &  topLeftCol,
const Color &  bottomRightCol,
bool  filled = true,
bool  outlined = false 
)

Constructor : with topLeft/bottomRight coords, topLeft/bottomRight colors and if GlRect is filled/outlined

tlp::GlRect::GlRect ( const Coord &  center,
const Size &  size,
const Color &  fillColor,
const Color &  outlineColor 
)

Constructor : with center coords and size, fill color and outline color

tlp::GlRect::GlRect ( bool  filled = true,
bool  outlined = false 
)

Constructor : with GlRect is filled/outlined

virtual tlp::GlRect::~GlRect ( )
virtual

Destructor


Member Function Documentation

virtual void tlp::GlRect::draw ( float  lod,
Camera camera 
)
virtual

Draw the GlRect

Reimplemented from tlp::GlAbstractPolygon.

Reimplemented in tlp::Gl2DRect.

virtual Color tlp::GlRect::getBottomRightColor ( )
virtual

Accessor in reading to the Bottom Right Corner Color of the Rectangle

virtual Coord tlp::GlRect::getBottomRightPos ( )
virtual

Accessor in reading to the Bottom Right Corner of the rectangle

virtual Coord tlp::GlRect::getCenter ( )
virtual

Accessor in reading to the Top Left Corner of the rectangle

virtual Color tlp::GlRect::getTopLeftColor ( )
virtual

Accessor in reading to the Top Left Corner Color of the rectangle

virtual Coord tlp::GlRect::getTopLeftPos ( )
virtual

Accessor in reading to the Top Left Corner of the rectangle

virtual void tlp::GlRect::getXML ( xmlNodePtr  rootNode)
virtual

Function to export data in XML

Reimplemented from tlp::GlAbstractPolygon.

Reimplemented in tlp::Gl2DRect.

bool tlp::GlRect::inRect ( double  x,
double  y 
)

Is the point in the rectangle ?

virtual void tlp::GlRect::setBottomRightColor ( const Color &  bottomRightCol)
virtual

Accessor in writing to the Bottom Right Corner Color of the rectangle

virtual void tlp::GlRect::setBottomRightPos ( const Coord &  bottomRightPos)
virtual

Accessor in writing to the Bottom Right Corner Color of the rectangle

void tlp::GlRect::setCenterAndSize ( const Coord &  center,
const Size &  size 
)

Set the center and the size of the GlRect

virtual void tlp::GlRect::setTopLeftColor ( const Color &  topLeftCol)
virtual

Accessor in writing to the Top Left Corner of the rectangle

virtual void tlp::GlRect::setTopLeftPos ( const Coord &  topLeftPos)
virtual

Accessor in writing to the Top Left Corner of the rectangle

virtual void tlp::GlRect::setWithXML ( xmlNodePtr  rootNode)
virtual

Function to set data with XML

Reimplemented from tlp::GlAbstractPolygon.

Reimplemented in tlp::Gl2DRect.



Tulip Software by LaBRI Visualization Team    2001 - 2012