MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ GlyphAtlas() [1/3]

MayaFlux::Portal::Text::GlyphAtlas::GlyphAtlas ( FontFace face,
uint32_t  pixel_size,
uint32_t  atlas_size = 512 
)
explicit

Construct an atlas for a specific face and pixel size.

Parameters
faceLoaded FontFace. Must outlive this atlas.
pixel_sizeGlyph height in pixels (width is derived by FreeType).
atlas_sizeWidth and height of the atlas texture in pixels. Must be a power of two. Default 512 is sufficient for ASCII + extended Latin at sizes up to ~48px.

Definition at line 7 of file GlyphAtlas.cpp.

8 : m_face(face)
11{
12 m_texture = std::make_unique<Kakshya::TextureContainer>(
14}
std::unique_ptr< Kakshya::TextureContainer > m_texture
uint32_t pixel_size() const
Pixel size passed at construction.
uint32_t atlas_size() const
Atlas texture dimension (width == height == atlas_size).

References atlas_size(), m_texture, and MayaFlux::Portal::Graphics::R8.

+ Here is the call graph for this function: