#include <GlLabel.h>
Public Member Functions |
| | GlLabel () |
| _DEPRECATED | GlLabel (Coord centerPosition, Coord size, Color fontColor, bool leftAlign=false) |
| | GlLabel (Coord centerPosition, Size size, Color fontColor, bool leftAlign=false) |
| _DEPRECATED | GlLabel (const std::string &fontPath, Coord centerPosition, Coord size, Color fontColor, bool leftAlign=false) |
| | ~GlLabel () |
| void | init () |
| void | setText (const std::string &text) |
| std::string | getText () const |
| void | setPosition (const Coord &position) |
| Coord | getPosition () |
| virtual void | setTranslationAfterRotation (Coord translation) |
| virtual Coord | getTranslationAfterRotation () |
| virtual void | setAlignment (int alignment) |
| virtual BoundingBox | getBoundingBox () |
| virtual BoundingBox | getTextBoundingBox () |
| virtual _DEPRECATED void | setSize (const Coord &size) |
| virtual void | setSize (const Size &size) |
| virtual Coord _DEPRECATED | getSize () |
| virtual Size | getLabelSize () const |
| virtual void | setSizeForOutAlign (const Size &size) |
| virtual void _DEPRECATED | setSizeForOutAlign (const Coord &size) |
| virtual Coord _DEPRECATED | getSizeForOutAlign () |
| virtual Size | getLabelSizeForOutAlign () const |
| virtual void | setColor (const Color &color) |
| virtual Color | getColor () |
| virtual void | enableDepthTest (bool state) |
| virtual void | setScaleToSize (bool state) |
| void | drawWithStencil (float lod, Camera *camera=NULL) |
| virtual void | draw (float lod, Camera *camera=NULL) |
| virtual void | translate (const Coord &mouvement) |
| virtual void | rotate (float xRot, float yRot, float zRot) |
| virtual void | getXML (xmlNodePtr rootNode) |
| virtual void | setWithXML (xmlNodePtr rootNode) |
| virtual void | setBoldFont () |
| virtual void | setPlainFont () |
| virtual void | setFontName (const std::string &name) |
| virtual void | setFontNameSizeAndColor (const std::string &name, const int &size, const Color &color) |
| virtual void | setRenderingMode (int mode) |
| virtual void | setOcclusionTester (OcclusionTest *tester) |
| virtual void | setUseLODOptimisation (bool state, BoundingBox bb=BoundingBox()) |
| virtual bool | getUseLODOptimisation () |
| virtual void | setLabelOcclusionBorder (int size) |
| virtual int | getLabelOcclusionBorder () |
| virtual void | setLabelsDensity (int density) |
| virtual int | getLabelDensity () |
| void | setMinSize (int size) |
| int | getMinSize () |
| void | setMaxSize (int size) |
| int | getMaxSize () |
| void | setUseMinMaxSize (bool state) |
| bool | isUsingMinMaxSize () |
| int | getFontSize () const |
| void | setFontSize (int size) |
| | Sets the font size used when rendering the label.
|
| Color | getOutlineColor () const |
| void | setOutlineColor (const Color &color) |
| | Sets the outline color used when rendering the label.
|
| float | getOutlineSize () const |
| void | setOutlineSize (float size) |
| | Sets the outline size used when rendering the label.
|
| std::string | getTextureName () const |
| void | setTextureName (const std::string &name) |
| | Sets the texture name used when rendering the label.
|
| bool | isBillboarded () |
| void | setBillboarded (bool billboarded) |
| | Set if the label is billboarded.
|
| | 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 void | addLayerParent (GlLayer *) |
| virtual void | removeLayerParent (GlLayer *) |
| void | addParent (GlComposite *composite) |
| void | removeParent (GlComposite *composite) |
| virtual | ~GlEntity () |
Detailed Description
Constructor & Destructor Documentation
| tlp::GlLabel::GlLabel |
( |
| ) |
|
| _DEPRECATED tlp::GlLabel::GlLabel |
( |
Coord |
centerPosition, |
|
|
Coord |
size, |
|
|
Color |
fontColor, |
|
|
bool |
leftAlign = false |
|
) |
| |
Contructor with fontPath, centerPosition, size, fontColor and alignment Use GlLabel(Coord centerPosition,Size size,Color fontColor,bool leftAlign=false) instead.
| tlp::GlLabel::GlLabel |
( |
Coord |
centerPosition, |
|
|
Size |
size, |
|
|
Color |
fontColor, |
|
|
bool |
leftAlign = false |
|
) |
| |
Contructor with fontPath, centerPosition, size, fontColor and alignment
| _DEPRECATED tlp::GlLabel::GlLabel |
( |
const std::string & |
fontPath, |
|
|
Coord |
centerPosition, |
|
|
Coord |
size, |
|
|
Color |
fontColor, |
|
|
bool |
leftAlign = false |
|
) |
| |
Contructor with fontPath, centerPosition, size, fontColor and alignment this constructor will be remove on Tulip 4 version
| tlp::GlLabel::~GlLabel |
( |
| ) |
|
Member Function Documentation
| virtual void tlp::GlLabel::draw |
( |
float |
lod, |
|
|
Camera * |
camera = NULL |
|
) |
| |
|
virtual |
| void tlp::GlLabel::drawWithStencil |
( |
float |
lod, |
|
|
Camera * |
camera = NULL |
|
) |
| |
Set the stencil and draw the Label, this function is usefull when we directly call draw without tulip engine
| virtual void tlp::GlLabel::enableDepthTest |
( |
bool |
state | ) |
|
|
inlinevirtual |
Enable/disable the depth test for the label (default depth test is enable)
| virtual BoundingBox tlp::GlLabel::getBoundingBox |
( |
| ) |
|
|
virtual |
| virtual Color tlp::GlLabel::getColor |
( |
| ) |
|
|
inlinevirtual |
Get color use to render the label
| int tlp::GlLabel::getFontSize |
( |
| ) |
const |
|
inline |
| virtual int tlp::GlLabel::getLabelDensity |
( |
| ) |
|
|
inlinevirtual |
Return label density of occlusion test This density must be in interval -100 100
| virtual int tlp::GlLabel::getLabelOcclusionBorder |
( |
| ) |
|
|
inlinevirtual |
Return label border for occlusion test
- Deprecated:
- Use getLabelsDensity instead
| virtual Size tlp::GlLabel::getLabelSize |
( |
| ) |
const |
|
virtual |
return the size of the text.
| virtual Size tlp::GlLabel::getLabelSizeForOutAlign |
( |
| ) |
const |
|
virtual |
return the size for alignment outside (left/right/top/bottom)
| int tlp::GlLabel::getMaxSize |
( |
| ) |
|
|
inline |
Get max screen size (in pixel) of the label : this size is used in not scaled mode
| int tlp::GlLabel::getMinSize |
( |
| ) |
|
|
inline |
Get min screen size (in pixel) of the label : this size is used in not scaled mode
| Color tlp::GlLabel::getOutlineColor |
( |
| ) |
const |
|
inline |
| float tlp::GlLabel::getOutlineSize |
( |
| ) |
const |
|
inline |
| Coord tlp::GlLabel::getPosition |
( |
| ) |
|
Return the position of the label
| virtual Coord _DEPRECATED tlp::GlLabel::getSize |
( |
| ) |
|
|
virtual |
return the size of the text. Deprecated use getLabelSize instead.
| virtual Coord _DEPRECATED tlp::GlLabel::getSizeForOutAlign |
( |
| ) |
|
|
virtual |
| std::string tlp::GlLabel::getText |
( |
| ) |
const |
| virtual BoundingBox tlp::GlLabel::getTextBoundingBox |
( |
| ) |
|
|
virtual |
Return the bounding box of the text of the label
| std::string tlp::GlLabel::getTextureName |
( |
| ) |
const |
|
inline |
- Returns
- the texture name used to render the label
| virtual Coord tlp::GlLabel::getTranslationAfterRotation |
( |
| ) |
|
|
inlinevirtual |
return the translation used after rotation of the label
| virtual bool tlp::GlLabel::getUseLODOptimisation |
( |
| ) |
|
|
inlinevirtual |
Return label border for occlusion test
| virtual void tlp::GlLabel::getXML |
( |
xmlNodePtr |
rootNode | ) |
|
|
virtual |
| void tlp::GlLabel::init |
( |
| ) |
|
| bool tlp::GlLabel::isBillboarded |
( |
| ) |
|
|
inline |
- Returns
- if the label is billboarded
| bool tlp::GlLabel::isUsingMinMaxSize |
( |
| ) |
|
|
inline |
Return if the label using min/max screen size in not scaled mode
| virtual void tlp::GlLabel::rotate |
( |
float |
xRot, |
|
|
float |
yRot, |
|
|
float |
zRot |
|
) |
| |
|
virtual |
| virtual void tlp::GlLabel::setAlignment |
( |
int |
alignment | ) |
|
|
inlinevirtual |
Set the alignment of the label : ON_CENTER, ON_TOP, ON_BOTTOM, ON_LEFT, ON_RIGHT
| void tlp::GlLabel::setBillboarded |
( |
bool |
billboarded | ) |
|
|
inline |
Set if the label is billboarded.
| virtual void tlp::GlLabel::setBoldFont |
( |
| ) |
|
|
virtual |
| virtual void tlp::GlLabel::setColor |
( |
const Color & |
color | ) |
|
|
inlinevirtual |
| virtual void tlp::GlLabel::setFontName |
( |
const std::string & |
name | ) |
|
|
virtual |
| virtual void tlp::GlLabel::setFontNameSizeAndColor |
( |
const std::string & |
name, |
|
|
const int & |
size, |
|
|
const Color & |
color |
|
) |
| |
|
virtual |
Change font name, size and color of the text
| void tlp::GlLabel::setFontSize |
( |
int |
size | ) |
|
|
inline |
Sets the font size used when rendering the label.
| virtual void tlp::GlLabel::setLabelOcclusionBorder |
( |
int |
size | ) |
|
|
inlinevirtual |
Set label border for occlusion test
- Deprecated:
- Use setLabelsDensity instead
| virtual void tlp::GlLabel::setLabelsDensity |
( |
int |
density | ) |
|
|
inlinevirtual |
Set labels density of occlusion test This density must be in interval -100 100
| void tlp::GlLabel::setMaxSize |
( |
int |
size | ) |
|
|
inline |
Set max screen size (in pixel) of the label : this size is used in not scaled mode
| void tlp::GlLabel::setMinSize |
( |
int |
size | ) |
|
|
inline |
Set min screen size (in pixel) of the label : this size is used in not scaled mode
| virtual void tlp::GlLabel::setOcclusionTester |
( |
OcclusionTest * |
tester | ) |
|
|
inlinevirtual |
Set the occlusion tester If occlusionTester is NULL : deactivate occlusion test
| void tlp::GlLabel::setOutlineColor |
( |
const Color & |
color | ) |
|
|
inline |
Sets the outline color used when rendering the label.
| void tlp::GlLabel::setOutlineSize |
( |
float |
size | ) |
|
|
inline |
Sets the outline size used when rendering the label.
| virtual void tlp::GlLabel::setPlainFont |
( |
| ) |
|
|
virtual |
| void tlp::GlLabel::setPosition |
( |
const Coord & |
position | ) |
|
Set the position used to render the label
| virtual void tlp::GlLabel::setRenderingMode |
( |
int |
mode | ) |
|
|
virtual |
Switch rendering mode to polygon- or texture-based rendering
| virtual void tlp::GlLabel::setScaleToSize |
( |
bool |
state | ) |
|
|
inlinevirtual |
Enable/disable if label is scaled to size
| virtual _DEPRECATED void tlp::GlLabel::setSize |
( |
const Coord & |
size | ) |
|
|
virtual |
Use setSize(const Size& size instead)
| virtual void tlp::GlLabel::setSize |
( |
const Size & |
size | ) |
|
|
virtual |
Set the size of the label
| virtual void tlp::GlLabel::setSizeForOutAlign |
( |
const Size & |
size | ) |
|
|
virtual |
Set the size for alignment outside (left/right/top/bottom) Warning : this size is reinit when you call setSize
| virtual void _DEPRECATED tlp::GlLabel::setSizeForOutAlign |
( |
const Coord & |
size | ) |
|
|
virtual |
| void tlp::GlLabel::setText |
( |
const std::string & |
text | ) |
|
Set the text of the label
| void tlp::GlLabel::setTextureName |
( |
const std::string & |
name | ) |
|
|
inline |
Sets the texture name used when rendering the label.
| virtual void tlp::GlLabel::setTranslationAfterRotation |
( |
Coord |
translation | ) |
|
|
inlinevirtual |
Set the translation used after rotation of the label
| virtual void tlp::GlLabel::setUseLODOptimisation |
( |
bool |
state, |
|
|
BoundingBox |
bb = BoundingBox() |
|
) |
| |
|
inlinevirtual |
Set if the label is otimized with the lod
| void tlp::GlLabel::setUseMinMaxSize |
( |
bool |
state | ) |
|
|
inline |
Set if the label use min/max screen size in not scaled mode
| virtual void tlp::GlLabel::setWithXML |
( |
xmlNodePtr |
rootNode | ) |
|
|
virtual |
| virtual void tlp::GlLabel::translate |
( |
const Coord & |
mouvement | ) |
|
|
virtual |
|