Blamite Game Engine - blam!  00296.01.12.21.0102.blamite
The core library for the Blamite Game Engine.
fonts.h File Reference
#include <d2d1.h>
#include <map>
#include <Windows.h>
#include <string>

Go to the source code of this file.

Classes

struct  Blam::Content::Fonts::FontGlyph
 Structure to contain data for a Font Glyph. More...
 
struct  Blam::Content::Fonts::Font
 Structure to contain data for a Font. More...
 

Namespaces

 Blam
 Namespace surrounding all major engine components.
 
 Blam::Content
 
 Blam::Content::Fonts
 

Macros

#define BLAM
 
#define FONTINFO_FILENAME   "fontinfo.xml"
 
#define FONT_PACKAGE_EXTENSION   ".bin"
 
#define FONT_PACKAGE_VERSION   2
 

Enumerations

enum  FontGlyphFormat { PNG }
 Enumerator for the image format used in a given font glyph. More...
 

Functions

BLAM void Blam::Content::Fonts::LoadAllFonts ()
 Loads all fonts available in the engine's configured font directory. More...
 
BLAM HRESULT Blam::Content::Fonts::LoadFont (std::string path)
 Load a font from disk. More...
 
BLAM HRESULT Blam::Content::Fonts::ReloadFont (std::string id)
 Reloads all data for the specified font. More...
 
BLAM FontBlam::Content::Fonts::GetFont (std::string id)
 Retrieves a font from the list of loaded fonts. More...
 
BLAM FontGlyphBlam::Content::Fonts::GetFontGlyph (Font *font, char glyph)
 Retrieves a glyph from a font. More...
 
BLAM bool Blam::Content::Fonts::FontExists (std::string id)
 Checks whether or not a font is loaded. More...
 
BLAM std::map< std::string, Font > * Blam::Content::Fonts::GetFontList ()
 Retrieves the list of loaded fonts. More...
 
BLAM void Blam::Content::Fonts::Cleanup ()
 Clean-up all font data and free any allocated memory for font data. More...
 

Macro Definition Documentation

◆ BLAM

#define BLAM

◆ FONT_PACKAGE_EXTENSION

#define FONT_PACKAGE_EXTENSION   ".bin"

◆ FONT_PACKAGE_VERSION

#define FONT_PACKAGE_VERSION   2

◆ FONTINFO_FILENAME

#define FONTINFO_FILENAME   "fontinfo.xml"

Enumeration Type Documentation

◆ FontGlyphFormat

Enumerator for the image format used in a given font glyph.

Currently, only PNG images are supported. We could support other image types - but we may end up just sticking with PNG since it isn't subject to any sort of compression. Because let's face it - compression is good for photos, not so good when you're dealing with pixel precise font textures.

Enumerator
PNG 

Indicates the glyph originates from a .PNG image.