Making app takes voice cmmands during a video call

Viewed 67

I am developing an Android application, the application is based on a video chat, I have implemented voice commands through the whole application using the SpeechRecognizer, the commands work just fine in the whole application except during the video call(because the microphone is already in use), when I click on the voice command, I hear the start voice alert, but when I talk, it does not respond, any idea how to get around this or to solve the problem.

1 Answers

I have solved it at the end of the day :)

first solution: just before I start the video chat, I launched the line of code responsible for the voice commands to give it thee priority over the video chat, this worked for me.

other solution: make "put on hold" to the call before launching the line of code responsible for receiving the command line.

Related