Equalizer  1.7.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
bitmapFont.h
1 
2 /* Copyright (c) 2008-2014, Stefan Eilemann <eile@equalizergraphics.com>
3  *
4  * This library is free software; you can redistribute it and/or modify it under
5  * the terms of the GNU Lesser General Public License version 2.1 as published
6  * by the Free Software Foundation.
7  *
8  * This library is distributed in the hope that it will be useful, but WITHOUT
9  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
10  * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
11  * details.
12  *
13  * You should have received a copy of the GNU Lesser General Public License
14  * along with this library; if not, write to the Free Software Foundation, Inc.,
15  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
16  */
17 
18 #ifndef EQUTIL_BITMAPFONT_H
19 #define EQUTIL_BITMAPFONT_H
20 
21 #include <eq/util/objectManager.h> // used inline
22 #include <eq/util/types.h>
23 
24 namespace eq
25 {
26 namespace util
27 {
29 class BitmapFont : public boost::noncopyable
30 {
31 public:
43  EQ_API BitmapFont( ObjectManager& gl, const void* key );
44 
52  EQ_API ~BitmapFont();
53 
69  EQ_API bool init( const WindowSystem& ws, const std::string& name,
70  const uint32_t size = 12 );
71 
73  EQ_API void exit();
74 
79  EQ_API void draw( const std::string& text ) const;
80 
81 private:
82  ObjectManager _gl;
83  const void* _key;
84 };
85 }
86 }
87 #endif // EQUTIL_BITMAPFONT_H
A wrapper around AGL, WGL and GLX bitmap fonts.
Definition: bitmapFont.h:29
EQ_API BitmapFont(ObjectManager &gl, const void *key)
Construct a new bitmap font.
EQ_API void exit()
De-initialize this bitmap font.
EQ_API void draw(const std::string &text) const
Draw text on the current raster position.
EQ_API bool init(const WindowSystem &ws, const std::string &name, const uint32_t size=12)
Initialize this bitmap font.
EQ_API ~BitmapFont()
Destruct this bitmap font.
A facility class to manage OpenGL objects across shared contexts.
Definition: objectManager.h:51