AvogadroLibs
1.96.0
|
The TextLabelBase class provides a generic implementation of a text drawable.
#include <avogadro/rendering/textlabelbase.h>
Public Member Functions | |
TextLabelBase (const TextLabelBase &other) | |
TextLabelBase & | operator= (TextLabelBase other) |
void | render (const Camera &camera) override |
Render the contents of the drawable. More... | |
void | buildTexture (const TextRenderStrategy &tren) |
void | resetTexture () |
void | setText (const std::string &str) |
const std::string & | text () const |
void | setTextProperties (const TextProperties &tprop) |
const TextProperties & | textProperties () const |
![]() | |
Drawable (const Drawable &other) | |
Drawable & | operator= (Drawable) |
virtual void | accept (Visitor &) |
const GeometryNode * | parent () const |
Get a pointer to the drawable object's parent. More... | |
GeometryNode * | parent () |
void | setVisible (bool visibility) |
Set the visibility of the drawable object. More... | |
bool | isVisible () const |
Get the current visibility of the drawable. More... | |
Identifier & | identifier () |
const Identifier & | identifier () const |
virtual std::multimap< float, Identifier > | hits (const Vector3f &rayOrigin, const Vector3f &rayEnd, const Vector3f &rayDirection) const |
virtual Core::Array< Identifier > | areaHits (const Frustrum &f) const |
virtual void | clear () |
void | setRenderPass (RenderPass pass) |
RenderPass | renderPass () const |
Protected Member Functions | |
void | setAnchorInternal (const Vector3f &anchor) |
Vector3f | getAnchorInternal () const |
void | setRadiusInternal (float radius) |
float | getRadiusInternal () const |
void | markDirty () |
![]() | |
void | setParent (GeometryNode *parent) |
Set the parent node for the node. More... | |
Protected Attributes | |
std::string | m_text |
TextProperties | m_textProperties |
Vector2i | m_imageDimensions |
Core::Array< unsigned char > | m_imageRgba |
![]() | |
GeometryNode * | m_parent |
bool | m_visible |
RenderPass | m_renderPass |
Identifier | m_identifier |
|
overridevirtual |
void buildTexture | ( | const TextRenderStrategy & | tren | ) |
Render the string to the internal texture buffer.
tren | The text rendering strategy to use. |
void setText | ( | const std::string & | str | ) |
The text that will be rendered.
const std::string& text | ( | ) | const |
The text that will be rendered.
void setTextProperties | ( | const TextProperties & | tprop | ) |
The properties of the rendered text.
const TextProperties& textProperties | ( | ) | const |
The properties of the rendered text.
void resetTexture | ( | ) |
Clear the texture, forcing it to be regenerated on the next render.