14 #include <fontconfig/fontconfig.h>
18 #include FT_FREETYPE_H
20 #include <adtf_base.h>
55 tBool m_bOpposedYAxis;
56 tBool m_bScaleWithCoordinateSystem;
57 tBool m_bRotationWithCoordinateSystem;
58 tBool m_bTextBaselineOnTop;
90 tResult
Create(
const cGLCanvas* pCanvas,
const char* strFilename, tInt nHeight,
tStyle eFontStyle);
108 void Print(tInt x, tInt y, tFloat64 fAngle,
const char* strFormat, va_list ArgList);
119 void Print(tFloat32 x, tFloat32 y, tFloat64 fAngle,
const char* strFormat, va_list ArgList);
163 tBool
MeasureText(
const char* str, tInt& nWidth, tInt& nHeight)
const;
187 void PrintImpl(tUInt32 ui32Flags, tFloat32 x, tFloat32 y, tFloat64 fAngle,
const char* strFormat, va_list ArgList);
Default Font handling interface for basic font support.
tStyle
The enumeration marks the style of the font.
virtual tResult Release()=0
Releases the font.
virtual tBool MeasureText(const tChar *str, tInt &nWidth, tInt &nHeight) const =0
The methods returns the measurement of the text in nWidth and nHeight.
virtual tInt GetHeight() const =0
This function returns the height of the font in point.
tResult Create(const cGLCanvas *pCanvas, const char *strFilename, tInt nHeight, tStyle eFontStyle)
Creates a font based on the given parameters.
static tResult Uninitialize()
Uninitialize the font.
GLuint m_nTextureBase
Base address of texture array.
tVoid FlipTextHorizontally(tBool bOpposedYAxis)
Set the text direction with or opposed the x-axis direction.
tInt m_aCharWidth[256]
Character width.
tVoid TextScaleWithCoordinateSystem(tBool bScaleWithCoordinateSystem)
Set the text to scale with the coordinatesystem.
tInt m_nHeight
Font height.
GLuint * m_hTextures
Texture array.
tResult BuildDisplayList(char ch, tStyle eFontStyle)
Creates a display list for the given character.
static tResult Initialize()
Initialize the font.
tVoid TextRotateWithCoordinateSystem(tBool bRotateWithCoordinateSystem)
Set the text to rotate with the coordinatesystem.
void Print(tInt x, tInt y, tFloat64 fAngle, const char *strFormat, va_list ArgList)
Print a string onto the screen.
tResult CleanUp()
Clean up the font.
void Print(tFloat32 x, tFloat32 y, tFloat64 fAngle, const char *strFormat, va_list ArgList)
Print a string onto the screen.
FT_Face m_hFace
FreeType face.
tVoid TextBaselineOnTop(tBool bTextBaselineOnTop)
Set the text baseline on the top of the text.
static constexpr tInt m_nTextureScale
Super sampling of internal texture.
void PrintImpl(tUInt32 ui32Flags, tFloat32 x, tFloat32 y, tFloat64 fAngle, const char *strFormat, va_list ArgList)
Internal print implementation.
Copyright © Audi Electronics Venture GmbH.