aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/others/irrlicht-1.8.1/tools/IrrFontTool/newFontTool/CFontTool.h
diff options
context:
space:
mode:
authorDavid Walter Seikel2016-03-28 22:28:34 +1000
committerDavid Walter Seikel2016-03-28 22:28:34 +1000
commit7028cbe09c688437910a25623098762bf0fa592d (patch)
tree10b5af58277d9880380c2251f109325542c4e6eb /src/others/irrlicht-1.8.1/tools/IrrFontTool/newFontTool/CFontTool.h
parentMove lemon to the src/others directory. (diff)
downloadSledjHamr-7028cbe09c688437910a25623098762bf0fa592d.zip
SledjHamr-7028cbe09c688437910a25623098762bf0fa592d.tar.gz
SledjHamr-7028cbe09c688437910a25623098762bf0fa592d.tar.bz2
SledjHamr-7028cbe09c688437910a25623098762bf0fa592d.tar.xz
Move Irrlicht to src/others.
Diffstat (limited to 'src/others/irrlicht-1.8.1/tools/IrrFontTool/newFontTool/CFontTool.h')
-rw-r--r--src/others/irrlicht-1.8.1/tools/IrrFontTool/newFontTool/CFontTool.h78
1 files changed, 78 insertions, 0 deletions
diff --git a/src/others/irrlicht-1.8.1/tools/IrrFontTool/newFontTool/CFontTool.h b/src/others/irrlicht-1.8.1/tools/IrrFontTool/newFontTool/CFontTool.h
new file mode 100644
index 0000000..5a35938
--- /dev/null
+++ b/src/others/irrlicht-1.8.1/tools/IrrFontTool/newFontTool/CFontTool.h
@@ -0,0 +1,78 @@
1#ifndef __IRR_FONT_TOOL_INCLUDED__
2#define __IRR_FONT_TOOL_INCLUDED__
3
4
5#include "irrlicht.h"
6
7#if defined(_IRR_WINDOWS_)
8 #ifdef _MBCS
9 #undef _MBCS
10 #endif
11
12 #define UNICODE
13 #define _WIN32_WINNT 0x0500
14 #include "windows.h"
15#else
16 #ifdef _IRR_COMPILE_WITH_X11_
17 #include <X11/Xlib.h>
18 #endif
19 #include <X11/Xft/Xft.h>
20 #include <set>
21#endif
22
23
24namespace irr {
25 class CFontTool : public irr::IReferenceCounted
26 {
27 public:
28 CFontTool(irr::IrrlichtDevice* device);
29 ~CFontTool();
30
31 virtual bool makeBitmapFont(u32 fontIndex, u32 charsetIndex,
32 s32 fontSize, u32 texturewidth, u32 textureHeight,
33 bool bold, bool italic, bool aa, bool alpha);
34
35 virtual bool saveBitmapFont(const c8* filename, const c8* format);
36
37 virtual void selectCharSet(u32 currentCharSet);
38
39 struct SFontArea
40 {
41 SFontArea() : rectangle(), underhang(0), overhang(0), sourceimage(0) {}
42 core::rect<s32> rectangle;
43 s32 underhang;
44 s32 overhang;
45 u32 sourceimage;
46 };
47
48 /* struct SFontMap
49 {
50 SFontMap() : areas(), start(0), count(0) {}
51 core::array< SFontArea > areas;
52 s32 start;
53 s32 count;
54 };*/
55
56
57
58 core::array<core::stringw> FontNames;
59 core::array<core::stringw> CharSets;
60 //core::array<SFontMap> Mappings;
61 core::array<SFontArea> Areas;
62 core::map<wchar_t, u32> CharMap;
63
64 core::array<video::ITexture*> currentTextures;
65 core::array<video::IImage*> currentImages;
66 const int *FontSizes;
67 IrrlichtDevice *Device;
68
69 bool UseAlphaChannel;
70
71 // windows
72 #ifdef _IRR_WINDOWS_
73 HDC dc;
74 #endif
75
76 };
77}
78#endif // __IRR_FONT_TOOL_INCLUDED__