My app waits for an input from the user for their gender: male or female. If the user chooses male, then the text-to-speech voice will be in a male's voice, if the user chooses female, it will be in female voice. The language is always English, I just want to change the gender of the TTS voice. How do I do that?
My code to initiate TTS:
TextToSpeech TTS;
TTS.setLanguage(new Locale("en_EN"));
TTS.speak("hello i am speaking in your gender",TextToSpeech.QUEUE_FLUSH,null,null);