Android record audio while doing speech recognition

前端 未结 1 1075
一个人的身影
一个人的身影 2021-02-06 12:43

I am doing speech recognition using a third party cloud service on Android, and it works well with Android API SpeechRecognizer. Code below:

    Intent recognize         


        
相关标签:
1条回答
  • 2021-02-06 12:55

    As the comments state, only one mic access is permitted/possible at a time.

    For the SpeechRecognizer the attached RecognitionListener has a callback of onBufferReceived(byte[] buffer) but unfortunately, Google's native recognition service does not supply any audio data to this, it's very frustrating.

    Your only alternative is to use an external service, which won't be free. Google's new Cloud Speech API has an Android example.

    0 讨论(0)
提交回复
热议问题