Closed ibrahim-iqbal closed 3 years ago
That's not going to work. Try the demo app on your device and check the code to achieve this: https://github.com/gotev/android-speech/blob/master/examples/demoapp/app/src/main/java/net/gotev/speechdemo/MainActivity.java#L168
You have to use one of the voices returned to you by the system and not creating a new object on your own
I'm trying to change the default voice to a male voice using the setVoice method, Bu t it doesn't seem to work
Speech.getInstance ( ).setVoice ( new Voice ( "en-us-x-sfg#male_1-local" , Locale.ENGLISH , Voice.QUALITY_HIGH , Voice.LATENCY_VERY_LOW , false , a ) );