GlPortal Class Reference  0.1.1
Source code documentation of the free and open 3D action puzzle game.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Member Functions | Private Attributes
radix::TextRenderer Class Reference

#include <external/RadixEngine/include/radix/renderer/TextRenderer.hpp>

Public Member Functions

 TextRenderer (World &w, Renderer &ren)
 
void render (double dtime)
 
void renderText (RenderContext &rc, Text text)
 Renders a string to the screen using signed-distance field text rendering. More...
 
int getTextWidth (std::string text, Font font)
 Meassures the width of text respecting the font. More...
 

Static Public Member Functions

static Matrix4f clipProjMat (const Entity &ent, const Matrix4f &view, const Matrix4f &proj)
 

Private Attributes

Worldworld
 
Rendererrenderer
 
std::unique_ptr< RenderContextrenderContext
 
double time
 

Constructor & Destructor Documentation

radix::TextRenderer::TextRenderer ( World w,
Renderer ren 
)

Member Function Documentation

static Matrix4f radix::TextRenderer::clipProjMat ( const Entity ent,
const Matrix4f view,
const Matrix4f proj 
)
static
int radix::TextRenderer::getTextWidth ( std::string  text,
Font  font 
)

Meassures the width of text respecting the font.

Parameters
text
font
Returns
Width in pixels
void radix::TextRenderer::render ( double  dtime)
void radix::TextRenderer::renderText ( RenderContext rc,
Text  text 
)

Renders a string to the screen using signed-distance field text rendering.

Parameters
textThe text to render

Field Documentation

std::unique_ptr<RenderContext> radix::TextRenderer::renderContext
private
Renderer& radix::TextRenderer::renderer
private
double radix::TextRenderer::time
private
World& radix::TextRenderer::world
private

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