You.i Engine
CYIFrameworkConfiguration Class Reference

Detailed Description

CYIFrameworkConfiguration is used to specify configuration settings for the CYIFramework class.

To configure CYIFramework, pass a configured instance of this class to CYIFramework::SetFrameworkConfiguration().

#include <framework/YiFrameworkConfiguration.h>

Public Member Functions

 CYIFrameworkConfiguration ()
 
virtual ~CYIFrameworkConfiguration ()
 
void SetMaxFonts (uint16_t maxFonts)
 
void SetTextAtlasSize (uint16_t fontAtlasSize, CYITextEngine::TextType textAtlasType=CYITextEngine::TextType::All)
 
uint16_t GetMaxFonts () const
 
uint16_t GetTextAtlasSize (CYITextEngine::TextType textAtlasType=CYITextEngine::TextType::All) const
 
const std::map< CYITextEngine::TextType, uint16_t > & GetTextAtlasSizes () const
 
void SetAudioEngineEnabled (bool enabled)
 
bool IsAudioEngineEnabled () const
 
void SetSpeechSynthesizerEnabled (bool enabled)
 
bool IsSpeechSynthesizerEnabled () const
 

Constructor & Destructor Documentation

◆ CYIFrameworkConfiguration()

CYIFrameworkConfiguration::CYIFrameworkConfiguration ( )

◆ ~CYIFrameworkConfiguration()

virtual CYIFrameworkConfiguration::~CYIFrameworkConfiguration ( )
virtual

Member Function Documentation

◆ GetMaxFonts()

uint16_t CYIFrameworkConfiguration::GetMaxFonts ( ) const

Returns the maximum number of fonts to cache.

◆ GetTextAtlasSize()

uint16_t CYIFrameworkConfiguration::GetTextAtlasSize ( CYITextEngine::TextType  textAtlasType = CYITextEngine::TextType::All) const

Returns the text atlas pixel dimension that the engine is configured to use for the specified textAtlasType.

Note
If textAtlasType is CYITextEngine::TextType::All and all text atlases are not the same size 0 will be returned, each atlas size will need to be queried individually in that case.
See also
SetTextAtlasSize

◆ GetTextAtlasSizes()

const std::map<CYITextEngine::TextType, uint16_t>& CYIFrameworkConfiguration::GetTextAtlasSizes ( ) const

Returns a map containing the current size for each text atlas type.

◆ IsAudioEngineEnabled()

bool CYIFrameworkConfiguration::IsAudioEngineEnabled ( ) const

Returns whether or not the Audio Engine will be enabled by this configuration. Default is true.

◆ IsSpeechSynthesizerEnabled()

bool CYIFrameworkConfiguration::IsSpeechSynthesizerEnabled ( ) const

Returns whether or not the Speech Synthesizer will be enabled by this configuration. Default is true.

See also
CYISpeechSynthesizer

◆ SetAudioEngineEnabled()

void CYIFrameworkConfiguration::SetAudioEngineEnabled ( bool  enabled)

Set whether to enable the Audio Engine or not. The default is true. If false, the Audio Engine won't be initialized, saving a small amount of memory and CPU time. Could be use if the app doesn't plan on playing sounds at all, or if it is using a third party audio engine.

Note
The Audio Engine is not responsible for playing audio from the video player. The audio in video player will still be heard even if the Audio Engine is not initialized.

◆ SetMaxFonts()

void CYIFrameworkConfiguration::SetMaxFonts ( uint16_t  maxFonts)

Sets the maximum number of fonts to cache. The default is 0, which will use the caching system's default value.

◆ SetSpeechSynthesizerEnabled()

void CYIFrameworkConfiguration::SetSpeechSynthesizerEnabled ( bool  enabled)

Set whether to enable the Speech Synthesizer or not. The default is true. If false, the Speech Synthesizer won't be initialized, saving a small amount of memory and CPU time.

Note
Accessibility support will indirectly be disabled as well if the platform uses the Speech Synthesizer for announcements.
See also
CYISpeechSynthesizer

◆ SetTextAtlasSize()

void CYIFrameworkConfiguration::SetTextAtlasSize ( uint16_t  fontAtlasSize,
CYITextEngine::TextType  textAtlasType = CYITextEngine::TextType::All 
)

Set the size of the text atlas in pixels. Specify textAtlasType to individually configure the size of the text atlas for each text type.

The font atlas is a square texture. This will set both the width and height of the texture.


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