使用 System.Speech.Recognition 打开 Windows 语音识别
我尝试用 C# 实现一些简单的语音识别 WinForms 程序,就像 Michael Levy 答案中描述的那样:
我遇到的问题是,每当我运行该程序时,Windows 语音识别都会打开,并且还会根据我所说的内容执行操作。另外,当程序启动时,我必须说“开始收听”才能使语音识别工作。
我的问题是:如何使用语音识别而不让 Windows 语音识别也按照我所说的进行操作?我根本不需要打开 Windows 语音识别 UI,并且我需要能够使用识别功能,而不必先说“开始收听”。
感谢您的回答
I tried implementing some simple speech recognition WinForms program in C# like the one described here in Michael Levy answer:
The problem i have is that any time i run the program Windows Speech Recognition opens and is also doing stuff based on what i am saying. Also when the program starts i have to say "start listening" for speech recognition to work.
My question is: How can i use speech recognition without having Windows Speech Recognition also act on what i am saying? I don't need Windows Speech Recognition UI to open at all and i need to be able to use recognition without having to say "start listening" before.
Thanks for your answers
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您确定仅在您的应用程序中使用 inproc 识别器吗?您可以通过在应用程序中实例化 SpeechRecognitionEngine() 来实现此目的。请参阅SpeechRecognitionEngine 类。我怀疑您正在实例化共享识别器 - 语音识别器类
Are you sure you are using an inproc recognizer for your application only. You do this by instantiating a SpeechRecognitionEngine() in your application. See SpeechRecognitionEngine Class. I suspect you are instantiating a shared recognizer - SpeechRecognizer Class