Note
Please see Azure Cognitive Services for Speech documentation for the latest supported speech solutions.
Microsoft Speech Platform
ISpVoice::SetRate
ISpVoice::SetRate sets the current text rendering rate.
<pre IsFakePre="true" xmlns="http://www.w3.org/1999/xhtml"> <strong>HRESULT SetRate(</strong> <strong> long</strong> <em>RateAdjust</em> <strong>);</strong> </pre>
Parameters
- RateAdjust
[in] Value specifying the speaking rate of the voice. Supported values range from -10 to 10 - values outside this range may be truncated.
Return Values
Value | Description |
---|---|
S_OK | Function completed successfully. |
E_INVALIDARG | One or more parameters are invalid. |
Remarks
Voices do not all have the same default rate. The granularity of the rate is voice-dependent.
Applications can adjust the rate of a voice either through this function call, or by embedding Speech Synthesis Markup Language (SSML) tags in the input text passed to the voice with a ISpVoice::Speak call. See Speech Synthesis Markup Language Reference. The voice should combine rate adjustments made in these two ways to arrive at a final rate.