저는 C# 응용 프로그램에서 .NET 말하기 인식 부분을 사용하여 기본적인 말하기 기능을 사용하고 있습니다.음성 인식을 사용하면서 오디오 데이터를 기록 하시겠습니까?
이 외에도 내 애플리케이션에서 인식 한 오디오를 내 애플리케이션과 동시에 인식하여 녹음 할 수 있습니까? 나중에 분석하여 분석 할 수 있습니다.
별도의 스레드를 만든 다음 마이크로 말할 때 .NET 오디오 녹음을 넣으시겠습니까? 그저 로컬 디렉토리에 .wav 형식으로 저장하고 싶습니다. 48khz 및 16 비트 샘플과 같은 간편한 녹음.
저는 정상적인 양식 응용 프로그램을 사용하고 있습니다. 이것은 지금 당신에게 아이디어를주기위한 음성 코드 유형입니다.
using System.Speech.Recognition;
//then inside the class and namespace I have
public partial class Form1 : Form
{
SpeechRecognitionEngine _recognizer = new SpeechRecognitionEngine();
//declared variables here
//now I initialize
public Form1()
{
InitializeComponent();
_recognizer.SetInputToDefaultAudioDevice();
_recognizer.LoadGrammar(new Grammar(new GrammarBuilder(new Choices(File.ReadAllLines(@"Commands.txt")))));
_recognizer.SpeechRecognized += new EventHandler<SpeechRecognizedEventArgs>(_recognizer_SpeechRecognized);
_recognizer.RecognizeAsync(RecognizeMode.Multiple);
systemOnline();
}
void _recognizer_SpeechRecognized(object sender, SpeechRecognizedEventArgs e)
{
string time = now.GetDateTimeFormats('t')[0];
int ranNum;
string speech = e.Result.Text;
switch (speech)
{
//Open Google
case "Google":
//code opens google in default browser
이미 메모리에 저장되어있는 것처럼 보입니다. 따라서 응용 프로그램에서 녹음을 해제하기 전에 파일에 메모리 위치를 보내야합니다. 나는 생각한다. – Malachi