vdr-plugin-softhddevice-drm-gles 1.6.4-d0291bb
cOglFont Class Reference

OpenGL OSD Representation of a VDR Font. More...

#include <openglosd.h>

Public Member Functions

virtual ~cOglFont (void)
 
cOglFontAtlasAtlas (void)
 
const charName (void)
 
int Size (void)
 
int Bottom (void)
 
int Height (void)
 
cOglGlyphGlyph (FT_ULong) const
 
int Kerning (cOglGlyph *glyph, FT_ULong prevSym) const
 

Static Public Member Functions

static cOglFontGet (const char *, int)
 
static void Cleanup (void)
 

Private Member Functions

 cOglFont (const char *, int)
 

Static Private Member Functions

static void Init (void)
 

Private Attributes

cString m_name
 
int m_size
 
int m_height = 0
 
int m_bottom = 0
 
FT_Face m_face
 
cList< cOglGlyphm_glyphCache
 
cOglFontAtlasm_pAtlas
 

Static Private Attributes

static bool s_initiated = false
 
static FT_Library s_ftLib = 0
 
static cList< cOglFont > * s_pFonts = 0
 

Detailed Description

OpenGL OSD Representation of a VDR Font.

Represents a OSD font (one per size and font family) using FreeType

Definition at line 202 of file openglosd.h.

Constructor & Destructor Documentation

◆ ~cOglFont()

cOglFont::~cOglFont ( void  )
virtual

Definition at line 510 of file openglosd.cpp.

References m_face, and m_pAtlas.

◆ cOglFont()

cOglFont::cOglFont ( const char fontName,
int  charHeight 
)
private

Definition at line 479 of file openglosd.cpp.

References L_OPENGL, LOGDEBUG2, LOGERROR, m_bottom, m_face, m_height, m_name, m_pAtlas, m_size, and s_ftLib.

Member Function Documentation

◆ Atlas()

cOglFontAtlas * cOglFont::Atlas ( void  )
inline

Definition at line 206 of file openglosd.h.

References m_pAtlas.

Referenced by cOglCmdDrawText::Execute().

◆ Bottom()

int cOglFont::Bottom ( void  )
inline

Definition at line 210 of file openglosd.h.

References m_bottom.

Referenced by cOglCmdDrawText::Execute().

◆ Cleanup()

void cOglFont::Cleanup ( void  )
static

Definition at line 542 of file openglosd.cpp.

References LOGERROR, s_ftLib, s_initiated, and s_pFonts.

Referenced by cOglThread::Cleanup().

◆ Get()

cOglFont * cOglFont::Get ( const char name,
int  charHeight 
)
static

Definition at line 516 of file openglosd.cpp.

References Init(), and s_pFonts.

Referenced by cOglCmdDrawText::Execute().

◆ Glyph()

cOglGlyph * cOglFont::Glyph ( FT_ULong  charCode) const

Definition at line 554 of file openglosd.cpp.

References code, FT_Errors, LOGERROR, m_face, m_glyphCache, message, and s_ftLib.

Referenced by cOglCmdDrawText::Execute().

◆ Height()

int cOglFont::Height ( void  )
inline

Definition at line 211 of file openglosd.h.

References m_height.

Referenced by cOglCmdDrawText::Execute().

◆ Init()

void cOglFont::Init ( void  )
staticprivate

Definition at line 532 of file openglosd.cpp.

References LOGERROR, s_ftLib, s_initiated, and s_pFonts.

Referenced by Get().

◆ Kerning()

int cOglFont::Kerning ( cOglGlyph glyph,
FT_ULong  prevSym 
) const

Definition at line 614 of file openglosd.cpp.

References KERNING_UNKNOWN, and m_face.

Referenced by cOglCmdDrawText::Execute().

◆ Name()

const char * cOglFont::Name ( void  )
inline

Definition at line 208 of file openglosd.h.

References m_name.

◆ Size()

int cOglFont::Size ( void  )
inline

Definition at line 209 of file openglosd.h.

References m_size.

Member Data Documentation

◆ m_bottom

int cOglFont::m_bottom = 0
private

Definition at line 222 of file openglosd.h.

Referenced by Bottom(), and cOglFont().

◆ m_face

FT_Face cOglFont::m_face
private

Definition at line 223 of file openglosd.h.

Referenced by cOglFont(), Glyph(), Kerning(), and ~cOglFont().

◆ m_glyphCache

cList<cOglGlyph> cOglFont::m_glyphCache
mutableprivate

Definition at line 224 of file openglosd.h.

Referenced by Glyph().

◆ m_height

int cOglFont::m_height = 0
private

Definition at line 221 of file openglosd.h.

Referenced by cOglFont(), and Height().

◆ m_name

cString cOglFont::m_name
private

Definition at line 219 of file openglosd.h.

Referenced by cOglFont(), and Name().

◆ m_pAtlas

cOglFontAtlas* cOglFont::m_pAtlas
private

Definition at line 225 of file openglosd.h.

Referenced by Atlas(), cOglFont(), and ~cOglFont().

◆ m_size

int cOglFont::m_size
private

Definition at line 220 of file openglosd.h.

Referenced by cOglFont(), and Size().

◆ s_ftLib

FT_Library cOglFont::s_ftLib = 0
staticprivate

Definition at line 216 of file openglosd.h.

Referenced by Cleanup(), cOglFont(), Glyph(), and Init().

◆ s_initiated

bool cOglFont::s_initiated = false
staticprivate

Definition at line 215 of file openglosd.h.

Referenced by Cleanup(), and Init().

◆ s_pFonts

cList< cOglFont > * cOglFont::s_pFonts = 0
staticprivate

Definition at line 217 of file openglosd.h.

Referenced by Cleanup(), Get(), and Init().


The documentation for this class was generated from the following files: