mElite  1.0
An Elite clone based on TextElite by Jan-Philipp Kappmeier and Melanie Schmidt.
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | List of all members
BitmapFont Class Reference

Bitmap represents windows bitmap font. More...

#include <BitmapFont.h>

Public Member Functions

 BitmapFont (HDC h)
 Constructor setting up the device context and the font size.
 
 ~BitmapFont ()
 Destructor.
 
GLvoid buildFont (GLvoid)
 Builds a BitmapFont on Microsoft Windows.
 
GLvoid buildFont (GLuint size)
 Builds a BitmapFont on Microsoft Windows.
 
GLvoid print (const char *fmt,...)
 Prints a text to the screen.
 
GLvoid killFont (GLvoid)
 Deletes the displaylists for all 96 characters.
 

Detailed Description

Bitmap represents windows bitmap font.

The font uses the supporting methods of the operating system to represent text on an OpenGL context. It has a proper windows font handle and the font is built by the system, in contrast to a TextureFont, where the font is loaded from symbols existing as an image that is used as a texture.

Author
Jan-Philipp Kappmeier
Date
27/09/2012

Definition at line 25 of file BitmapFont.h.

Constructor & Destructor Documentation

BitmapFont::BitmapFont ( HDC  h)

Constructor setting up the device context and the font size.

Definition at line 12 of file BitmapFont.cpp.

BitmapFont::~BitmapFont ( )

Destructor.

The Font is destroyed and deleted from the GDI-Space.

Definition at line 22 of file BitmapFont.cpp.

Member Function Documentation

GLvoid BitmapFont::buildFont ( GLvoid  )

Builds a BitmapFont on Microsoft Windows.

Definition at line 29 of file BitmapFont.cpp.

GLvoid BitmapFont::buildFont ( GLuint  size)

Builds a BitmapFont on Microsoft Windows.

Parameters
sizesize of the font (in pixel, not usual font size)

Definition at line 60 of file BitmapFont.cpp.

GLvoid BitmapFont::killFont ( GLvoid  )

Deletes the displaylists for all 96 characters.

Definition at line 68 of file BitmapFont.cpp.

GLvoid BitmapFont::print ( const char *  fmt,
  ... 
)

Prints a text to the screen.

The text is allowed to be up to 256 chars. Old C-Style functions are used.

Definition at line 77 of file BitmapFont.cpp.


The documentation for this class was generated from the following files: