protected void Recognizer_SpeechRecognized(object sender, Microsoft.Speech.Recognition.SpeechRecognizedEventArgs e)
 {
     if (SpeechRecognized != null && e.Result.Confidence > RecognitionConfidence)
     {
         SpeechRecognized(this, e);
     }
 }
Exemplo n.º 2
0
        void VoiceController_SpeechRecognized(object sender, Microsoft.Speech.Recognition.SpeechRecognizedEventArgs e)
        {
            string text = e.Result.Text;

            tb.Text  = text;
            tb2.Text = "qw";
            voiceController.Speak("I recognized the words: " + text);
        }
Exemplo n.º 3
0
        void VoiceController_SpeechRecognized(object sender, Microsoft.Speech.Recognition.SpeechRecognizedEventArgs e)
        {
            string text = e.Result.Text;

            //tb.Text = text;
            // tb2.Text = "qw";
            counter = 0;

            // voiceController.Speak("I recognized the words: " + text);
            //SpeechSynthesizer speechSynthesizer = new SpeechSynthesizer();
            speechSynthesizer.SpeakAsync("Restarting");
        }
Exemplo n.º 4
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);
        }
Exemplo n.º 5
0
        private void Sr_SpeechRecognized(object sender, Microsoft.Speech.Recognition.SpeechRecognizedEventArgs e)
        {
            string frase = e.Result.Text;

            switch (frase)
            {
            case "Oi": rtbDialogo.Text = frase; ss.SpeakAsync("Oi, meu chapa"); break;

            case "Olá": rtbDialogo.Text = frase; ss.SpeakAsync("Olá meu bom"); break;

            case "Teste": rtbDialogo.Text = frase; ss.SpeakAsync("Deu certo"); break;

            case "Emprestimo": rtbDialogo.Text = frase; ss.SpeakAsync("Iniciando novo empréstimo"); break;
            }
        }
Exemplo n.º 6
0
 static void recognizer_SpeechRecognized(object sender, SpeechRecognizedEventArgs e)
 {
     Console.Write(e.Result.Text);
 }