【C#】语音识别 - System.Speech】的更多相关文章

一个有趣的东西,今后可能用得上. C#语音识别:在命名空间 System.Speech下SpeechSynthesizer可以将文字转换成语音 贴出代码: public partial class Form1 : Form { private SpeechSynthesizer ss; public Form1() { InitializeComponent(); } private void Form1_Load(object sender, EventArgs e) { ss = new S…
using System; using System.Collections.Generic; using System.Linq; using System.Speech.Recognition; using System.Text; using System.Threading.Tasks; using System.Windows; using System.Windows.Controls; using System.Windows.Data; using System.Windows.…
本程序是口算两位数乘法,随机生成两个两位数,用语音读出来.然后开启语音识别,接受用户输入,知道答案正确关闭语音识别.用户说答案时,可以说“再说一遍”重复题目. 关键是GrammarBuilder和Choices的用法. 首先来看看如何获得已安装的语音识别引擎 void showInstalled() { Console.WriteLine("installed recognizers"); foreach (var i in SpeechRecognitionEngine.Instal…
C# 使用System.Speech 进行语音播报和识别 using System.Speech.Synthesis; using System.Speech.Recognition; //语音识别 SpeechRecognitionEngine recEngine = new SpeechRecognitionEngine(); SpeechSynthesizer speech = new SpeechSynthesizer(); //**************************使用S…
为了方便调用暂停.继续的方法.要将speech的功能写成一个类.直接附上代码: using System; using System.Collections.Generic; using System.Linq; using System.Speech.Synthesis; using System.Text; using System.Speech; namespace WindowsFormsApplication1 { public class TextToSpeak { //想要实现暂停…
using System; using System.Speech.Synthesis; namespace testvoice { class Program { static void Main(string[] args) { SpeechSynthesizer synth = new SpeechSynthesizer(); //获取本机上所安装的所有的Voice的名称 string voicestring = ""; foreach (InstalledVoice iv in…
使用微软语音库 使用微软语音库可以很快速的制作一个小应用,比如一个唐诗的朗诵工具.本示例也是使用微软语音库,制作了一个唐诗宋词朗诵的应用,仅供加深学习印象 首先是要引入System.Speech库 然后using System.Speech.Synthesis; 此后就可以使用SpeechSynthesizer实例对象来朗诵了 主要代码: using System; using System.Collections.Generic; using System.ComponentModel; us…
1.原理 语音操控分为 语音识别和语音朗读两部分. 这两部分本来是需要自然语言处理技能相关知识以及一系列极其复杂的算法才能搞定,可是这篇文章将会跳过此处,如果你只是对算法和自然语言学感兴趣的话,就只有请您移步了,下面没有一个字会讲述到这些内容. 早在上世纪90年代的时候,IBM就推出了一款极为强大的语音识别系统-vio voice , 而其后相关产品层出不穷,不断的进化和演变着. 我们这里将会使用SAPI实现语音模块. 2. 什么是SAPI? SAPI是微软Speech API , 是微软公司推…
最近突发奇想 想玩玩  文字转语音的东东   谷歌了一下 发现微软有一个TTS 的SDK   查了查相关资料  发现 还真不错  然后就开始玩玩Microsoft Speech SDK的 DEMO了 现在网上最新版好像是Microsoft Speech SDK Version 5.1    先下载下来 下载地址是  http://www.52z.com/soft/22068.html 要先安装第一个SDK 然后安装语言包    只有安装了语言包   语言包是用来支持中文翻读的 然后开始我们的C#…
在.NET4.0中,我可以借助System.Speech组件让电脑来识别我们的声音. 以上,当我说"name",显示"Darren",我说"age",显示"永远21".如何做呢? 首先要开启电脑的语音识别功能. 右键电脑右下方的扬声器,选择"录音设备". 点击默认的"麦克风",再点击左下角的"配置"按钮. 点击"启动语音识别". 一系列简单设置后,…