I have a list of words which I want to convert the text to voice functionality for PhoneGap iPhone. Is there any API or Plugin for TTS? Please let me know of any alternatives.
-
http://stackoverflow.com/questions/1102244/iphone-api-for-text-to-speech-feature – Kiran Sep 17 '12 at 23:12
3 Answers
because there is not any phonegap way(javascript) way to do this i recommend using one of the native TTS opensource libraries like :
https://bitbucket.org/sfoster/iphone-tts/src
or
https://github.com/todoroo/iPhone-Speech-To-Text
and then connect them to your javascript-html code with simple plugin(find more about writing a plugin : http://docs.phonegap.com/en/2.0.0/guide_plugin-development_index.md.html
just simple as that!

- 1,731
- 2
- 17
- 33
-
thanks..will it work in android os??,bcoz i'm developing this app in android os for phonegap iphone.. – pujitav Sep 18 '12 at 11:15
-
for android you need a TTS java library there are some like : http://freetts.sourceforge.net/docs/index.php and then connect it with a simple plugin – Duke Sep 18 '12 at 11:27
Did you check the Github repo for PhoneGap Plugins? (Located here: https://github.com/phonegap/phonegap-plugins) There is indeed a TTS plugin for Android: https://github.com/phonegap/phonegap-plugins/tree/master/Android/TTS

- 10,661
- 3
- 34
- 68
-
thanks for the reply,even i could found the same,but i want to implement only for IOS devices rather than android.. – pujitav Sep 03 '12 at 12:53
-
The cordova plugin tts works in iPhone:
TTS
.speak('hello, world!', function () {
alert('text spoken');
}, function (reason) {
alert(reason);
});
The plugin uses the AVSpeechSynthesizer class in iOS and works in Android, Windows Phone too.

- 2,930
- 4
- 23
- 49