#include <FTVectoriser.h>
Public Member Functions | |
FTVectoriser (const FT_GlyphSlot glyph) | |
virtual | ~FTVectoriser () |
void | MakeMesh (FTGL_DOUBLE zNormal=FTGL_FRONT_FACING) |
const FTMesh * | GetMesh () const |
size_t | PointCount () |
size_t | ContourCount () const |
const FTContour * | Contour (unsigned int index) const |
size_t | ContourSize (int c) const |
int | ContourFlag () const |
FTVectoriser (const FT_GlyphSlot glyph) | |
virtual | ~FTVectoriser () |
void | MakeMesh (FTGL_DOUBLE zNormal=FTGL_FRONT_FACING) |
const FTMesh * | GetMesh () const |
size_t | PointCount () |
size_t | ContourCount () const |
const FTContour * | Contour (unsigned int index) const |
size_t | ContourSize (int c) const |
int | ContourFlag () const |
Private Member Functions | |
void | ProcessContours () |
void | ProcessContours () |
Private Attributes | |
FTContour ** | contourList |
FTMesh * | mesh |
short | ftContourCount |
int | contourFlag |
FT_Outline | outline |
FTContour ** | contourList |
FTMesh * | mesh |
Definition at line 178 of file FTVectoriser.h.
FTVectoriser::FTVectoriser | ( | const FT_GlyphSlot | glyph | ) |
Constructor
glyph | The freetype glyph to be processed |
Definition at line 101 of file FTVectoriser.cxx.
References contourFlag, contourList, FT_Outline_::flags, ftContourCount, FT_Outline_::n_contours, outline, FT_GlyphSlotRec_::outline, and ProcessContours().
FTVectoriser::~FTVectoriser | ( | ) | [virtual] |
Destructor
Definition at line 120 of file FTVectoriser.cxx.
References c, ContourCount(), contourList, mesh, and size_t.
FTVectoriser::FTVectoriser | ( | const FT_GlyphSlot | glyph | ) |
Constructor
glyph | The freetype glyph to be processed |
virtual FTVectoriser::~FTVectoriser | ( | ) | [virtual] |
Destructor
void FTVectoriser::MakeMesh | ( | FTGL_DOUBLE | zNormal = FTGL_FRONT_FACING |
) |
Build an FTMesh from the vector outline data.
zNormal | The direction of the z axis of the normal for this mesh |
Definition at line 175 of file FTVectoriser.cxx.
References c, ContourCount(), contourFlag, contourList, d, ft_outline_even_odd_fill, ftglBegin(), ftglCombine(), ftglEnd(), ftglError(), ftglVertex(), mesh, p, and size_t.
Referenced by FTExtrdGlyph::FTExtrdGlyph(), and FTPolyGlyph::FTPolyGlyph().
const FTMesh* FTVectoriser::GetMesh | ( | ) | const [inline] |
Get the current mesh.
Definition at line 204 of file FTVectoriser.h.
Referenced by FTExtrdGlyph::FTExtrdGlyph(), and FTPolyGlyph::FTPolyGlyph().
size_t FTVectoriser::PointCount | ( | ) |
Get the total count of points in this outline
Definition at line 157 of file FTVectoriser.cxx.
References c, ContourCount(), contourList, s, and size_t.
Referenced by FTExtrdGlyph::FTExtrdGlyph(), FTOutlineGlyph::FTOutlineGlyph(), and FTPolyGlyph::FTPolyGlyph().
size_t FTVectoriser::ContourCount | ( | ) | const [inline] |
Get the count of contours in this outline
Definition at line 218 of file FTVectoriser.h.
Referenced by Contour(), FTExtrdGlyph::FTExtrdGlyph(), FTOutlineGlyph::FTOutlineGlyph(), FTPolyGlyph::FTPolyGlyph(), MakeMesh(), PointCount(), and ~FTVectoriser().
const FTContour * FTVectoriser::Contour | ( | unsigned int | index | ) | const |
Return a contour at index
Definition at line 169 of file FTVectoriser.cxx.
References ContourCount(), contourList, and NULL.
Referenced by FTExtrdGlyph::FTExtrdGlyph(), and FTOutlineGlyph::FTOutlineGlyph().
size_t FTVectoriser::ContourSize | ( | int | c | ) | const [inline] |
Get the number of points in a specific contour in this outline
c | The contour index |
Definition at line 233 of file FTVectoriser.h.
int FTVectoriser::ContourFlag | ( | ) | const [inline] |
Get the flag for the tesselation rule for this outline
Definition at line 240 of file FTVectoriser.h.
Referenced by FTExtrdGlyph::FTExtrdGlyph().
void FTVectoriser::ProcessContours | ( | ) | [private] |
Process the freetype outline data into contours of points
Definition at line 132 of file FTVectoriser.cxx.
References contourList, FT_Outline_::contours, ftContourCount, outline, FT_Outline_::points, and FT_Outline_::tags.
Referenced by FTVectoriser().
void FTVectoriser::MakeMesh | ( | FTGL_DOUBLE | zNormal = FTGL_FRONT_FACING |
) |
Build an FTMesh from the vector outline data.
zNormal | The direction of the z axis of the normal for this mesh |
const FTMesh* FTVectoriser::GetMesh | ( | ) | const [inline] |
Get the current mesh.
Definition at line 204 of file FTVectoriser.h.
size_t FTVectoriser::PointCount | ( | ) |
Get the total count of points in this outline
size_t FTVectoriser::ContourCount | ( | ) | const [inline] |
Get the count of contours in this outline
Definition at line 218 of file FTVectoriser.h.
const FTContour* FTVectoriser::Contour | ( | unsigned int | index | ) | const |
Return a contour at index
size_t FTVectoriser::ContourSize | ( | int | c | ) | const [inline] |
Get the number of points in a specific contour in this outline
c | The contour index |
Definition at line 233 of file FTVectoriser.h.
int FTVectoriser::ContourFlag | ( | ) | const [inline] |
Get the flag for the tesselation rule for this outline
Definition at line 240 of file FTVectoriser.h.
void FTVectoriser::ProcessContours | ( | ) | [private] |
Process the freetype outline data into contours of points
FTContour** FTVectoriser::contourList [private] |
The list of contours in the glyph
Definition at line 251 of file FTVectoriser.h.
Referenced by Contour(), FTVectoriser(), MakeMesh(), PointCount(), ProcessContours(), and ~FTVectoriser().
FTMesh* FTVectoriser::mesh [private] |
A Mesh for tesselations
Definition at line 256 of file FTVectoriser.h.
Referenced by MakeMesh(), and ~FTVectoriser().
short FTVectoriser::ftContourCount [private] |
The number of contours reported by Freetype
Definition at line 261 of file FTVectoriser.h.
Referenced by FTVectoriser(), and ProcessContours().
int FTVectoriser::contourFlag [private] |
A flag indicating the tesselation rule for the glyph
Definition at line 266 of file FTVectoriser.h.
Referenced by FTVectoriser(), and MakeMesh().
FT_Outline FTVectoriser::outline [private] |
A Freetype outline
Definition at line 271 of file FTVectoriser.h.
Referenced by FTVectoriser(), and ProcessContours().
FTContour** FTVectoriser::contourList [private] |
The list of contours in the glyph
Definition at line 251 of file FTVectoriser.h.
FTMesh* FTVectoriser::mesh [private] |
A Mesh for tesselations
Definition at line 256 of file FTVectoriser.h.