如何使用 ssml 韵律元素产生情感演讲?
我试过这段代码在语音中产生悲伤的情绪,但语音情绪没有变化。
static void Main(string[] args)
{
SpeechSynthesizer synth = new SpeechSynthesizer();
PromptBuilder pb1 = new PromptBuilder();
string sad = "<prosody pitch=\"-20%\" range=\"low\" rate =\"50%\" volume =\"30\"><emphasis level=\"none\">... She was sad. Ellen cried. Calvin said, I feel guilty. Calvin told Daddy Sam that he broke the lamp.</emphasis></prosody>";
pb1.AppendSsmlMarkup(sad);
synth.Speak(pb1);
}