pylips.speech.SystemTTS
- class pylips.speech.SystemTTS[source]
A text-to-speech backend that uses the system’s default TTS engine.
- Parameters
None –
Methods
__init__()gen_audio_and_visemes(text[, voice_id, fname])Generates audio and visemes from a string of text using the system's default TTS engine.
get_audio_and_visemes(fname)Gets the audio and visemes from a file that was previously generated.
Lists all the voices that are available in the system's default TTS backend.
- gen_audio_and_visemes(text, voice_id=None, fname=None)[source]
Generates audio and visemes from a string of text using the system’s default TTS engine.
- Parameters
- Returns
a tuple containing
fname,times, andvisemes. fname is the path to the audio file, times is a list of times that correspond to the initiation of the visemes, and visemes is a list of visemes that correspond to the words in the audio- Return type
(tuple)
- Raises
Exception – if the voice_id is not in the list of available voices
- get_audio_and_visemes(fname)[source]
Gets the audio and visemes from a file that was previously generated.
- Parameters
fname (str) – the name of the file that the audio and visemes were saved to. It is not necessary to include the file extension.
- Returns
a tuple containing
fname,times, andvisemes. fname is the path to the audio file, times is a list of times that correspond to the initiation of the visemes, and visemes is a list of visemes that correspond to the words in the audio- Return type
(tuple)