COSC345CoolGroupASLtoSpeech
BridgingASLandspokenlanguagewithAI:Translategesturestospeechforinclusivecommunication.
|
The TextToSpeech class represents the text-to-speech functionality. More...
#include <ttsCall.h>
Public Member Functions | |
bool | tts (const std::string &text) |
Converts the given text to speech using an external tool. More... | |
std::string | getString () |
Returns the current string that is being converted to speech. More... | |
void | setPitch (int s) |
void | setSpeed (int s) |
void | setVolume (int s) |
void | setGender (int gender) |
The TextToSpeech class represents the text-to-speech functionality.
This class represents the text-to-speech functionality. It provides a function to convert text to speech using an external tool.
std::string TextToSpeech::getString | ( | ) |
Returns the current string that is being converted to speech.
This function is used to return the current string that is going to be converted to speech.
void TextToSpeech::setGender | ( | int | gender | ) |
void TextToSpeech::setPitch | ( | int | s | ) |
void TextToSpeech::setSpeed | ( | int | s | ) |
void TextToSpeech::setVolume | ( | int | s | ) |
bool TextToSpeech::tts | ( | const std::string & | text | ) |
Converts the given text to speech using an external tool.
This function takes a text input, constructs a command using the input text, and executes the command using an external text-to-speech tool. The resulting audio can be played using appropriate audio playback functions.
text | The input text to convert to speech. |