예제 #1
0
 protected void OnSpeechRecognized(SpeechRecognizedEventArgs e)
 {
     if (this.SpeechRecognized != null)
         this.SpeechRecognized(this, e);
 }
예제 #2
0
        void speechRecognitionEngine_SpeechRecognized(object sender, Microsoft.Speech.Recognition.SpeechRecognizedEventArgs e)
        {
            var args = new SpeechRecognizedEventArgs { Text = e.Result.Text };
            if (e.Result.Semantics.Value != null)
                args.Value = e.Result.Semantics.Value.ToString();

            args.Confidence = e.Result.Confidence;

            this.OnSpeechRecognized(args);
        }