Text To Speech Voice & Accents

 Text To Speech Voice & Accents


Simple code to change your text to speech voice or accent.

Codes:
tts = new TextToSpeech(getApplicationContext(), new TextToSpeech.OnInitListener(){
@Override public void onInit(int status){
if(status != TextToSpeech.ERROR){
tts.setLanguage(new Locale("fil-ph"));
}
}});

tts - Text To Speech ID
fil-ph - Your Language Code (https://cloud.google.com/text-to-speech/docs/voices)

Comments

Popular posts from this blog

Number with Comma (9,999)

Get X, Y Position of Layout

Get Percent of the Number (98%)