Castor3D 0.12.0
Multiplatform 3D engine
Public Types | Public Member Functions | Public Attributes | List of all members
castor3d::FontTexture Class Reference

#include <FontTexture.hpp>

Inheritance diagram for castor3d::FontTexture:
Inheritance graph
[legend]
Collaboration diagram for castor3d::FontTexture:
Collaboration graph
[legend]

Public Types

using OnChangedFunction = std::function< void(FontTexture const &) >
 
using OnChanged = castor::SignalT< OnChangedFunction >
 

Public Member Functions

 CU_DeclareMap (char32_t, castor::Position, GlyphPosition)
 
C3D_API FontTexture (Engine &engine, castor::FontResPtr font)
 Constructor. More...
 
C3D_API ~FontTexture ()
 Destructor. More...
 
C3D_API void initialise (RenderDevice const &device, QueueData const &queueData)
 Initialises the texture. More...
 
C3D_API void cleanup (RenderDevice const &device)
 Flushes the teture. More...
 
C3D_API void update ()
 Updates the glyphs. More...
 
C3D_API castor::String const & getFontName () const
 Retrieves the font name. More...
 
C3D_API castor::Position const & getGlyphPosition (char32_t glyphChar) const
 Retrieves the wanted glyph position. More...
 
castor::FontRPtr getFont () const
 Retrieves the font. More...
 
TextureLayoutSPtr getTexture () const
 Retrieves the texture. More...
 
SamplerResPtr getSampler () const
 Retrieves the texture. More...
 

Public Attributes

OnChanged onChanged
 

Member Typedef Documentation

◆ OnChanged

◆ OnChangedFunction

using castor3d::FontTexture::OnChangedFunction = std::function< void( FontTexture const & ) >

Constructor & Destructor Documentation

◆ FontTexture()

C3D_API castor3d::FontTexture::FontTexture ( Engine engine,
castor::FontResPtr  font 
)

Constructor.

Parameters
[in]engineThe engine.
[in]fontThe font.

◆ ~FontTexture()

C3D_API castor3d::FontTexture::~FontTexture ( )

Destructor.

Member Function Documentation

◆ cleanup()

C3D_API void castor3d::FontTexture::cleanup ( RenderDevice const &  device)

Flushes the teture.

◆ CU_DeclareMap()

castor3d::FontTexture::CU_DeclareMap ( char32_t  ,
castor::Position  ,
GlyphPosition   
)

◆ getFont()

castor::FontRPtr castor3d::FontTexture::getFont ( ) const
inline

Retrieves the font.

Returns
The value.

◆ getFontName()

C3D_API castor::String const & castor3d::FontTexture::getFontName ( ) const

Retrieves the font name.

Returns
The value.

◆ getGlyphPosition()

C3D_API castor::Position const & castor3d::FontTexture::getGlyphPosition ( char32_t  glyphChar) const

Retrieves the wanted glyph position.

Parameters
[in]glyphCharThe glyph index.
Returns
The position.

◆ getSampler()

SamplerResPtr castor3d::FontTexture::getSampler ( ) const
inline

Retrieves the texture.

Returns
The texture.

◆ getTexture()

TextureLayoutSPtr castor3d::FontTexture::getTexture ( ) const
inline

Retrieves the texture.

Returns
The texture.

◆ initialise()

C3D_API void castor3d::FontTexture::initialise ( RenderDevice const &  device,
QueueData const &  queueData 
)

Initialises the texture.

Parameters
[in]deviceThe GPU device.
[in]queueDataThe queue receiving the GPU commands.

◆ update()

C3D_API void castor3d::FontTexture::update ( )

Updates the glyphs.

Member Data Documentation

◆ onChanged

OnChanged castor3d::FontTexture::onChanged

The signal used to notify clients that this texture has changed.


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