MeVisLabToolboxReference
|
FTGL based implementation of View2DFont. More...
#include <View2DFontFTGL.h>
Public Member Functions | |
View2DFontFTGL () | |
virtual | ~View2DFontFTGL () |
virtual bool | init (const char *fontname=NULL) |
init with given font (either just a font name without .ttf or an absolute path) requires a valid GL context! | |
virtual int | getFontHeight (float fontSize) const |
get height of font (ascender + descender) | |
virtual int | getFontAscender (float fontSize) const |
get ascender of font | |
virtual int | getFontDescender (float fontSize) const |
get descender of font | |
virtual int | getStringWidth (float fontSize, const char *string, int len) const |
get width of simple string | |
virtual void | drawString (float dx, float dy, float fontSize, const float *color, const char *string, int length, bool shadow=true) |
draws a simple string with no linefeeds, the drawing starts at the top-left corner |
FTGL based implementation of View2DFont.
Definition at line 19 of file View2DFontFTGL.h.
View2DFontFTGL::View2DFontFTGL | ( | ) |
virtual View2DFontFTGL::~View2DFontFTGL | ( | ) | [virtual] |
virtual void View2DFontFTGL::drawString | ( | float | dx, |
float | dy, | ||
float | fontSize, | ||
const float * | color, | ||
const char * | string, | ||
int | length, | ||
bool | shadow = true |
||
) | [virtual] |
draws a simple string with no linefeeds, the drawing starts at the top-left corner
Implements View2DFont.
virtual int View2DFontFTGL::getFontAscender | ( | float | fontSize | ) | const [virtual] |
get ascender of font
Implements View2DFont.
virtual int View2DFontFTGL::getFontDescender | ( | float | fontSize | ) | const [virtual] |
get descender of font
Implements View2DFont.
virtual int View2DFontFTGL::getFontHeight | ( | float | fontSize | ) | const [virtual] |
get height of font (ascender + descender)
Implements View2DFont.
virtual int View2DFontFTGL::getStringWidth | ( | float | fontSize, |
const char * | string, | ||
int | len | ||
) | const [virtual] |
get width of simple string
Implements View2DFont.
virtual bool View2DFontFTGL::init | ( | const char * | fontname = NULL | ) | [virtual] |
init with given font (either just a font name without .ttf or an absolute path) requires a valid GL context!
Implements View2DFont.