Changes for FTPoint
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
diff --git a/include/FTGlyphContainer.h b/include/FTGlyphContainer.h
index c071a64..1c2e74e 100755
--- a/include/FTGlyphContainer.h
+++ b/include/FTGlyphContainer.h
@@ -8,6 +8,7 @@
#include "FTGL.h"
#include "FTVector.h"
#include "FTGlyph.h"
+#include "FTPoint.h"
class FTFace;
@@ -71,7 +72,7 @@ class FTGL_EXPORT FTGlyphContainer
* @param pen the position to render the glyph
* @return The distance to advance the pen position after rendering
*/
- FT_Vector& render( unsigned int index, unsigned int next, FT_Vector pen);
+ FTPoint render( unsigned int index, unsigned int next, FTPoint pen);
/**
* Queries the Font for errors.
@@ -97,16 +98,6 @@ class FTGL_EXPORT FTGlyphContainer
FTFace* face;
/**
- * The kerning vector for the current pair of glyphs
- */
- FT_Vector kernAdvance;
-
- /**
- * The advance for the glyph being rendered
- */
- float advance;
-
- /**
* A structure to hold the glyphs
*/
typedef FTVector<FTGlyph*> GlyphVector;
diff --git a/src/FTGlyphContainer.cpp b/src/FTGlyphContainer.cpp
index 4db818b..0fe9eb0 100755
--- a/src/FTGlyphContainer.cpp
+++ b/src/FTGlyphContainer.cpp
@@ -59,9 +59,10 @@ float FTGlyphContainer::Advance( unsigned int index, unsigned int next)
}
-FT_Vector& FTGlyphContainer::render( unsigned int index, unsigned int next, FT_Vector pen)
+FTPoint FTGlyphContainer::render( unsigned int index, unsigned int next, FTPoint pen)
{
- kernAdvance.x = 0; kernAdvance.y = 0;
+ FTPoint kernAdvance;
+ float advance = 0;
unsigned int left = face->CharIndex( index);
unsigned int right = face->CharIndex( next);