Changeset 3696 in orxonox.OLD for orxonox/branches/textEngine/src/lib/graphics/font/glfont.h
- Timestamp:
- Mar 31, 2005, 4:34:05 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/textEngine/src/lib/graphics/font/glfont.h
r3694 r3696 43 43 { 44 44 public: 45 GLFont(const char* fontFile , unsigned int fontSize = FONT_DEFAULT_SIZE);45 GLFont(const char* fontFile); 46 46 virtual ~GLFont(); 47 47 … … 59 59 void createTexture(void); 60 60 61 void renderText(void);62 void renderText(const char* text, int x, int y);63 64 61 virtual void draw(void); 65 62 66 63 private: 67 64 // information about the Font 68 TTF_Font* font; 69 char* fontFile; 70 char* text; 71 unsigned int fontSize; 72 SDL_Color color; 65 TTF_Font* font; //!< The font we use for this. 66 char* fontFile; //!< The fontfile from whitch the font was loaded. 67 char* text; //!< The text to display 68 unsigned int fontSize; //!< The size of the font in pixels 69 SDL_Color color; //!< The color of the font. 73 70 74 71 // placement in openGL 75 GLuint texture; 76 SDL_Rect textPosSize; //!< A SDL-Rectangle representing the position and size of the Text on the screen. 77 int positionX; 78 int positionY; 79 int width; 80 int height; 81 int renderStyle; 82 SDL_Surface* surface; 83 GLfloat* texcoord; 72 GLuint texture; //!< A GL-texture to hold the text 73 SDL_Rect textPosSize; //!< An SDL-Rectangle representing the position and size of the Text on the screen. 74 int renderStyle; //!< The Renderstyle 75 GLfloat* texcoord; //!< Texture-coordinates \todo fix this to have a struct 84 76 85 77 bool init(const char* fontFile, unsigned int fontSize = FONT_DEFAULT_SIZE);
Note: See TracChangeset
for help on using the changeset viewer.