Programming Reference:TextToSpeech Class

From BCI2000 Wiki
Jump to: navigation, search




The TextToSpeech class is a wrapper for synthetic speech audio output. TextToSpeech objects may be stored in STL containers.


For each property, there is a getter method carrying the plain property name. Writable properties have an additional setter method prefixed with "Set".

string Text (rw)

The text to be spoken. This text is provided to the underlying text-to-speech engine unchanged, and may contain control characters as defined by that engine.

For speech markup defined by the Microsoft TTS Engine, see

float Volume (rw)

Playback volume in the range 0.0 to 1.0.

bool IsSpeaking (r)

True when text is currently spoken, false otherwise.


Default Constructor, Destructor

These provide the full set of methods required to use TextToSpeech as a data type in STL containers, such as std::vector<TextToSpeech>.


Starts speaking.


Stops speaking, and resets the speaking position to the beginning. This method does nothing when no speaking is performed.

See also

Programming Reference:WavePlayer Class, Programming Reference:MidiPlayer Class