/********************************************************************* * * * FLY * * --E#Y#E-- * * ===MUSCLE=== * * * *********************************************************************/ #ifndef FONT_H #define FONT_H /* CPP Header Files */ #include #include #include #include #include #include #include #include #include #include #include /* OpenGL Header */ #include #include #include #include /* Header Files */ #include "../WIN/win.h" #include "../TEX/targa.h" #include "../TEX/texture.h" #include "../CONF/config.h" #include "../CONF/uniform.h" #include "../CONF/geometry.h" #include "../OGL/cockpit.h" #include "../OGL/opengl.h" //--------------------------------------------------------------------------- using std::string; using std::ifstream; using std::map; using std::vector; /* Class Font */ class TMFONT { public: /* Mono Font */ bool TMFont(const GLchar* textureName, int screenWidth, int screenHeight, float fontSize); void MipmapsImage(const GLint count, int side3, GLubyte *pixel); bool initFont(); void printString(const GLchar* str, float x, float y); private: /* Buffer */ float w_texCoords5[EV]; float w_vertices5[EV]; const GLchar* m_textureName; GLuint m_textureID; float m_fontSize; int m_Width; int m_Height; /* Ortho Mode */ void setOrthoMode(); void unsetOrthoMode(); }; //--------------------------------------------------------------------------- #endif