FTGLPixmapFont.h

Go to the documentation of this file.
00001 #ifndef     __FTGLPixmapFont__
00002 #define     __FTGLPixmapFont__
00003 
00004 
00005 #include "FTFont.h"
00006 #include "FTGL.h"
00007 
00008 
00009 class FTGlyph;
00010 
00011 
00012 /**
00013  * FTGLPixmapFont is a specialisation of the FTFont class for handling
00014  * Pixmap (Grey Scale) fonts
00015  *
00016  * @see     FTFont
00017  */
00018 class FTGL_EXPORT FTGLPixmapFont : public FTFont
00019 {
00020     public:
00021         /**
00022          * Open and read a font file. Sets Error flag.
00023          *
00024          * @param fontFilePath  font file path.
00025          */
00026         FTGLPixmapFont( const char* fontFilePath);
00027         
00028         /**
00029          * Open and read a font from a buffer in memory. Sets Error flag.
00030          *
00031          * @param pBufferBytes  the in-memory buffer
00032          * @param bufferSizeInBytes  the length of the buffer in bytes
00033          */
00034         FTGLPixmapFont( const unsigned char *pBufferBytes, size_t bufferSizeInBytes);
00035         
00036         /**
00037          * Destructor
00038          */
00039         ~FTGLPixmapFont();
00040         
00041         /**
00042          * Prepare for rendering
00043          */
00044         virtual void PreRender();
00045 
00046         /**
00047          * Cleanup after rendering
00048          */
00049         virtual void PostRender();
00050 
00051     private:
00052         /**
00053          * Construct a FTPixmapGlyph.
00054          *
00055          * @param g The glyph index NOT the char code.
00056          * @return  An FTPixmapGlyph or <code>null</code> on failure.
00057          */
00058         inline virtual FTGlyph* MakeGlyph( unsigned int g);
00059         
00060 };
00061 
00062 
00063 #endif  //  __FTGLPixmapFont__
00064 

Generated on Tue Jul 5 14:16:15 2011 for ROOT_528-00b_version by  doxygen 1.5.1