Public Types |
| enum | AlignmentType {
LEFT_TOP,
LEFT_CENTER,
LEFT_BOTTOM,
CENTER_TOP,
CENTER_CENTER,
CENTER_BOTTOM,
RIGHT_TOP,
RIGHT_CENTER,
RIGHT_BOTTOM
} |
| enum | BoundingBoxType { GEOMETRY,
GLYPH
} |
| enum | DrawModeType { TEXT = 1<<0,
BOUNDINGBOX = 1<<1,
ALIGNMENT = 1<<2,
DEFAULT = TEXT
} |
Public Methods |
| | Text () |
| | Text (const Text &text, const osg::CopyOp ©op=osg::CopyOp::SHALLOW_COPY) |
| | Text (Font *font) |
| virtual osg::Object * | cloneType () const |
| | Clone the type of an object, with Object* return type.
|
| virtual osg::Object * | clone (const osg::CopyOp ©op) const |
| virtual bool | isSameKindAs (const osg::Object *obj) const |
| virtual const char * | className () const |
| | return the name of the object's class type.
|
| virtual const char * | libraryName () const |
| | return the name of the object's library.
|
| void | setPosition (const osg::Vec2 &pos) |
| void | setPosition (const osg::Vec3 &pos) |
| const osg::Vec3 & | getPosition () const |
| void | setColor (const osg::Vec4 &color) |
| osg::Vec4 & | getColor () |
| const osg::Vec4 & | getColor () const |
| void | setDrawMode (int mode) |
| int | getDrawMode () const |
| void | setBoundingBox (int mode) |
| int | getBoundingBox () const |
| void | setAlignment (int alignment) |
| int | getAlignment () const |
| void | setFont (Font *font) |
| Font * | getFont () |
| const Font * | getFont () const |
| void | setText (const char *text) |
| void | setText (const std::string &text) |
| const std::string & | getText () const |
| virtual void | drawImmediateMode (osg::State &state) |
| | draw directly ignoring an OpenGL display list which could be attached.
|
| virtual void | drawBoundingBox (void) |
| virtual void | drawAlignment (void) |
| const osg::Vec3 & | getAlignmentPos () const |
Protected Types |
| enum | FontType {
UNDEF,
BITMAP,
PIXMAP,
OUTLINE,
POLYGON,
TEXTURE
} |
Protected Methods |
| virtual | ~Text () |
| virtual void | setDefaults (void) |
| virtual const bool | computeBound (void) const |
| | compute the bounding box of the drawable.
|
| virtual void | calcBounds (osg::Vec3 *min, osg::Vec3 *max) const |
| void | initAlignment (osg::Vec3 *min, osg::Vec3 *max) |
| bool | initAlignment (void) |
Protected Attributes |
| osg::ref_ptr< Font > | _font |
| bool | _init |
| bool | _initAlignment |
| std::string | _text |
| int | _fontType |
| int | _alignment |
| int | _drawMode |
| int | _boundingBoxType |
| osg::Vec3 | _pos |
| osg::Vec3 | _alignmentPos |
| osg::Vec4 | _color |