gotev / android-speech

Android speech recognition and text to speech made easy
http://gotev.github.io/android-speech/
Apache License 2.0
473 stars 156 forks source link

Speech Recognition doesnt work #49

Closed n-droidev closed 3 years ago

n-droidev commented 3 years ago

Speech recognition doesnt work.. It calls onSpeechResult method immediately after onStartOfSpeech method.

n-droidev commented 3 years ago

Library cant recognize speech offline.

gotev commented 3 years ago

More details?

n-droidev commented 3 years ago

I didnt know what is the problem.. But I realized that Library cant recognize speech with setPreferOffline method.. Briefly if I call setPreferOffline(true) method, Library cant recognize speech. Stops immediately..

n-droidev commented 3 years ago

And I have another question.. How Can I make library recognize speech in other languages. It recognize only english. Even after I set Speech.getInstance(this).setLocale(Locale.Something).

gotev commented 3 years ago

The library is a wrapper over Google Voice Search. If that doesn't work it means offline voice settings on the device are not enabled and the language you tried is not downloaded. You can try the demo app and I think you will get the same result. This is unfortunately out of the scope of the library and you have to look at Google voice Search native interface. As far as I know there's no way to force or request a language to be downloaded for offline usage.

n-droidev commented 3 years ago

Ok.. Thank you very much.