More seperate cc files, font & overlay rendering

This commit is contained in:
2015-02-13 15:46:18 +01:00
parent 05bf47c678
commit e3ec085cf0
19 changed files with 925 additions and 449 deletions

26
font.hh Normal file
View File

@@ -0,0 +1,26 @@
#ifndef __OPENGLPLAYGROUND_FONT_HH__
#define __OPENGLPLAYGROUND_FONT_HH__
#include <string>
struct _TTF_Font;
typedef struct _TTF_Font TTF_Font;
class Texture2D;
class Font {
public:
Font(std::string const& filename, unsigned ptsize);
Font(Font const& copy) = delete;
Font& operator=(Font const& copy) = delete;
~Font();
Texture2D render(std::string const& text, bool fast = false) const;
private:
TTF_Font* font_;
};
#endif