FTGL: FTBufferFont.h Source File

FTGL 2.1.3~rc5

- Main Page
- Related Pages
- Namespaces
- Data Structures
- Files

- File List
- Globals

FTBufferFont.h
Go to the documentation of this file.
1 /*
2 * FTGL - OpenGL font library
3 *
4 * Copyright (c) 2008 Sam Hocevar <sam@zoy.org>
5 *
6 * Permission is hereby granted, free of charge, to any person obtaining
7 * a copy of this software and associated documentation files (the
8 * "Software"), to deal in the Software without restriction, including
9 * without limitation the rights to use, copy, modify, merge, publish,
10 * distribute, sublicense, and/or sell copies of the Software, and to
11 * permit persons to whom the Software is furnished to do so, subject to
12 * the following conditions:
13 *
14 * The above copyright notice and this permission notice shall be
15 * included in all copies or substantial portions of the Software.
16 *
17 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
18 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
19 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
20 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
21 * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
22 * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
23 * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
24 */
25
26 #ifndef __ftgl__
27 # warning Please use <FTGL/ftgl.h> instead of <FTBufferFont.h>.
28 # include <FTGL/ftgl.h>
29 #endif
30
31 #ifndef __FTBufferFont__
32 #define __FTBufferFont__
33
34 #ifdef __cplusplus
35
36
43 class FTGL_EXPORT FTBufferFont : public FTFont
44 {
45 public:
51 FTBufferFont(const char* fontFilePath);
52
61 FTBufferFont(const unsigned char *pBufferBytes,
62 size_t bufferSizeInBytes);
63
67 ~FTBufferFont();
68
69 protected:
79 virtual FTGlyph* MakeGlyph(FT_GlyphSlot slot);
80 };
81
82 #endif //__cplusplus
83
84 FTGL_BEGIN_C_DECLS
85
94 FTGL_EXPORT FTGLfont *ftglCreateBufferFont(const char *file);
95
96 FTGL_END_C_DECLS
97
98 #endif // __FTBufferFont__
99
ftgl.h
FTGLfont
struct _FTGLfont FTGLfont
Definition: FTFont.h:399
FTGL_EXPORT
#define FTGL_EXPORT
Definition: ftgl.h:107
FTFont::FTBufferFont
friend class FTBufferFont
Definition: FTFont.h:79
ftglCreateBufferFont
FTGLfont * ftglCreateBufferFont(const char *file)
Create a specialised FTGLfont object for handling memory buffer fonts.
FTFont::MakeGlyph
virtual FTGlyph * MakeGlyph(FT_GlyphSlot slot)=0
Construct a glyph of the correct type.
FTBufferFont
FTBufferFont is a specialisation of the FTFont class for handling memory buffer fonts.
Definition: FTBufferFont.h:43
FTGL_END_C_DECLS
#define FTGL_END_C_DECLS
Definition: ftgl.h:44
FTGL_BEGIN_C_DECLS
#define FTGL_BEGIN_C_DECLS
Definition: ftgl.h:43
FTFont
FTFont is the public interface for the FTGL library.
Definition: FTFont.h:56
FTGlyph
FTGlyph is the base class for FTGL glyphs.
Definition: FTGlyph.h:50