Main Page | Class Hierarchy | Compound List | File List | Compound Members | File Members

FTGlyph Class Reference

FTGlyph is the base class for FTGL glyphs. More...

#include <FTGlyph.h>

Inheritance diagram for FTGlyph:

FTBitmapGlyph FTExtrdGlyph FTOutlineGlyph FTPixmapGlyph FTPolyGlyph FTTextureGlyph List of all members.

Public Member Functions

 FTGlyph (FT_Glyph glyph)
 Constructor.

virtual ~FTGlyph ()
 Destructor.

virtual float Render (const FTPoint &pen)=0
 Renders this glyph at the current pen position.

float Advance () const
 Return the advance width for this glyph.

const FTBBoxBBox () const
 Return the bounding box for this glyph.

FT_Error Error () const
 Queries for errors.


Protected Attributes

float advance
 The advance distance for this glyph.

FTBBox bBox
 The bounding box of this glyph.

FT_Error err
 Current error code.


Detailed Description

FTGlyph is the base class for FTGL glyphs.

It provides the interface between Freetype glyphs and their openGL renderable counterparts. This is an abstract class and derived classes must implement the render function.

See also:
FTGlyphContainer

FTBBox

FTPoint

Definition at line 25 of file FTGlyph.h.


Constructor & Destructor Documentation

FTGlyph::FTGlyph FT_Glyph  glyph  ) 
 

Constructor.

Definition at line 4 of file FTGlyph.cpp.

References advance, and bBox.

FTGlyph::~FTGlyph  )  [virtual]
 

Destructor.

Definition at line 16 of file FTGlyph.cpp.


Member Function Documentation

float FTGlyph::Advance  )  const [inline]
 

Return the advance width for this glyph.

Returns:
advance width.

Definition at line 51 of file FTGlyph.h.

const FTBBox& FTGlyph::BBox  )  const [inline]
 

Return the bounding box for this glyph.

Returns:
bounding box.

Definition at line 58 of file FTGlyph.h.

FT_Error FTGlyph::Error  )  const [inline]
 

Queries for errors.

Returns:
The current error code.

Definition at line 65 of file FTGlyph.h.

virtual float FTGlyph::Render const FTPoint pen  )  [pure virtual]
 

Renders this glyph at the current pen position.

Parameters:
pen The current pen position.
Returns:
The advance distance for this glyph.

Implemented in FTBitmapGlyph, FTExtrdGlyph, FTOutlineGlyph, FTPixmapGlyph, FTPolyGlyph, and FTTextureGlyph.


Member Data Documentation

float FTGlyph::advance [protected]
 

The advance distance for this glyph.

Definition at line 71 of file FTGlyph.h.

Referenced by FTGlyph(), FTTextureGlyph::Render(), FTPolyGlyph::Render(), FTPixmapGlyph::Render(), FTOutlineGlyph::Render(), FTExtrdGlyph::Render(), and FTBitmapGlyph::Render().

FTBBox FTGlyph::bBox [protected]
 

The bounding box of this glyph.

Definition at line 76 of file FTGlyph.h.

Referenced by FTExtrdGlyph::FTExtrdGlyph(), and FTGlyph().

FT_Error FTGlyph::err [protected]
 

Current error code.

Zero means no error.

Definition at line 81 of file FTGlyph.h.

Referenced by FTBitmapGlyph::FTBitmapGlyph(), FTPixmapGlyph::FTPixmapGlyph(), and FTTextureGlyph::FTTextureGlyph().


The documentation for this class was generated from the following files:
Generated on Mon Aug 25 15:16:40 2003 for FTGL by doxygen 1.3.3