April 2020
Intermediate to advanced
380 pages
9h 24m
English
After adding the speech_recognition plugin and importing the package, we are all set to use it in our application. Let's start by adding methods that will handle speech recognition inside the application, as follows:
SpeechRecognition _speechRecognition;bool _isAvailable = false;bool _isListening = false;String transcription = '';
_speechRecognition is an instance of SpeechRecognition. _isAvailable is important as it lets the platform (Android/iOS) know that we are interacting with it and that _isListening will be used to check whether the application is currently listening to the microphone or not.
Initially, we set the values of both boolean variables to false. transcription ...
Read now
Unlock full access