You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am working on Google Speech by c # . I want to use the microphone . My code is there But My code uses only audio files. Please help me . Thank you
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Google.Cloud.Speech.V1Beta1;
namespace ConsoleApplication2
{
class Program
{
static void Main(string[] args)
{
var speech = SpeechClient.Create();
var response = speech.SyncRecognize(new RecognitionConfig()
{
LanguageCode = "tr-TR",
Encoding = RecognitionConfig.Types.AudioEncoding.Linear16,
SampleRate = 16000,
}, RecognitionAudio.FromFile("audio.wav"));
foreach (var result in response.Results)
{
foreach (var alternative in result.Alternatives)
{
Console.WriteLine(alternative.Transcript);
} }
Console.ReadLine();
}}}
The text was updated successfully, but these errors were encountered:
I am working on Google Speech by c # . I want to use the microphone . My code is there But My code uses only audio files. Please help me . Thank you
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Google.Cloud.Speech.V1Beta1;
namespace ConsoleApplication2
{
class Program
{
static void Main(string[] args)
{
var speech = SpeechClient.Create();
var response = speech.SyncRecognize(new RecognitionConfig()
{
LanguageCode = "tr-TR",
Encoding = RecognitionConfig.Types.AudioEncoding.Linear16,
SampleRate = 16000,
}, RecognitionAudio.FromFile("audio.wav"));
foreach (var result in response.Results)
{
foreach (var alternative in result.Alternatives)
{
Console.WriteLine(alternative.Transcript);
} }
Console.ReadLine();
}}}
The text was updated successfully, but these errors were encountered: