TTS语音如何变化 [英] How TTS voice change

查看:86
本文介绍了TTS语音如何变化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

先生们,大家好:

我在comboBox中收到(LH Michael,Microsoft Mary等.)声音,但是当我从comboBox中选择声音时,它不会更改voice.it,它会得到我在Windows中选择的默认声音.当我运行代码时,也不会给出任何错误.
谢谢大家.

mycode是:
私有void Form1_Load(对象发送者,EventArgs e)
{
foreach(spvoice.GetVoices(string.Empty,string.Empty)中的ISpeechObjectToken令牌)
{
comboBox1.Items.Add(token.GetAttribute("Name"));
}
comboBox1.SelectedIndex = 0;
}
私有void comboBox1_SelectedIndexChanged(对象发送者,EventArgs e)
{
spvoice.Voice = spvoice.GetVoices("Name =" + comboBox1.Items [0] .ToString(),string.Empty).Item(0);
}

Hi to all gentleman:

i get(LH Michael,Microsoft Mary etc..) voice in comboBox but when I select voice from comboBox it does not change voice.it get the default voice which i choose in windows.when i run the code does not give any error also.
thanks from all .

mycode is:
private void Form1_Load(object sender, EventArgs e)
{
foreach (ISpeechObjectToken token in spvoice.GetVoices(string.Empty, string.Empty))
{
comboBox1.Items.Add(token.GetAttribute("Name"));
}
comboBox1.SelectedIndex = 0;
}
private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
{
spvoice.Voice = spvoice.GetVoices("Name="+comboBox1.Items[0].ToString(), string.Empty).Item(0);
}

推荐答案

[ ^ ]文章做到了(非常)略有不同.看看是否有帮助.

在这种情况下,请记住Google是您的朋友.我使用 c#tts语音更改作为搜索短语.
This[^] article does it (very) slightly differently. Have a look to see if it helps.

Remember google is your friend in these circumstances. I used c# tts voice change as my search phrase.


这篇关于TTS语音如何变化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆