VoiceSearch app
This app illustrates the following:
When clicking on the Press the button to speak option, the user is prompted to say some words.
The user speaks some words.
VoiceSearch
initiates a search query based on the words spoken by the user.
The opening screen has a button asking the user to press and speak. On pressing the button, the next screen displays the Google speech prompt What is your query? The results are displayed in a browser window.
In this case, the app uses the two libraries developed previously: TTSLib
(see Chapter 2, Text-to-Speech Synthesis) and ASRLib
(see Chapter 3, Speech Recognition). Their jar
files are included in the libs
folder of the VoiceSearch
project. The ASR methods are used to recognize the user input and use it as the search criterion. The TTS is employed to provide spoken feedback to the user about the status of the app.
This app combines the code that was already presented for the TTSWithLib
(Chapter 2, Text-to-Speech Synthesis) and the ASRWithLib
...