TextToSpeechPause(3dtk)

Name

TextToSpeechPause - Pauses text-to-speech audio output.

Syntax
    MMRESULT TextToSpeechPause (LPTTS_HANDLE_T phTTS)

Parameters

LPTTS_HANDLE_T phTTS
    Specifies an opened text-to-speech handle.

Description

This function pauses text-to-speech audio output. This call affects only the audio output and has no effect when writing log files or wave files, or when using the speech-to-memory capability of the text-to-speech system.

If the text-to-speech system owns the audio device (that is, OWN_AUDIO_DEVICE was specified in the startup function), then the text-to-speech system remains paused until TextToSpeechResume(), TextToSpeechSync(), TextToSpeechOpenInMemory(), TextToSpeechOpenLogFile(), or TextToSpeechOpenWaveOutFile() is called.

If the text-to-speech system does not own the audio device (OWN_AUDIO_DEVICE was NOT specified in the startup function) and TextToSpeechPause() is called while the system is speaking, the text-to-speech system remains paused until the system has completed speaking. In this case, the wave output device is released when TextToSpeechReset() is called. It will also be released if TextToSpeechSync(), TextToSpeechOpenInMemory(), TextToSpeechOpenLogFile(), or TextToSpeechOpenWaveOutFile() is called AND the system has completed speaking.

Note that TextToSpeechPause() will NOT resume audio output if the text-to-speech system is paused by TextToSpeechPause().

Return Values

This function returns a value of type MMRESULT. The value is zero if the function is successful. The return value is one of the following constants:

Constant | Description
MMSYSERR_NOERROR
 | Normal successful completion (zero).
MMSYSERR_INVALHANDLE
 | The specified device handle is invalid. The system is not speaking or the text-to-speech handle is invalid.

See Also

TextToSpeechOpenInMemory(3dtk), TextToSpeechOpenLogFile(3dtk), TextToSpeechOpenWaveOutFile(3dtk), TextToSpeechReset(3dtk), TextToSpeechResume(3dtk), TextToSpeechSpeak(3dtk), TextToSpeechSync(3dtk)