my application is to convert text to voice. if i open one text file, it should read the text file in audio speech form. please give me java code for doing this.i need to open a text file which has a audioclip for it and when i press for example the word "hi" it should play the sound.i dont know how to add a audioclip on my program pls help me.
am using freetts to convert text to speech. i followed the instructions given in the following site
IRC Text to Speech with Java - O'Reilly Media
i compiled it and i didnt get any error.
but when i run it gets struck and i couldnt run it from tat on. and am not clear wat is IRC server. i run this in command prompt. should i use any other? in this,,,
java -classpath .;./lib/pircbot.jar;./lib/freetts.jar
SpeechBot irc.freenode.net #irchacks wat is the #irchacks. should i use the same thing while running it? please help me am trying this for long days am not getting. thanks.
I don't think IRC has got anything to do with text to speech conversion. Java Speech API deals with this. Personally I haven't worked on this, but the following links might help you
Java Speech API Frequently Asked Questions
FreeTTS 1.2 - A speech synthesizer written entirely in the Java(TM) programming language
ok thanks.. is there any other way to call audio file for text file. for eg, if i open the text file it should cal the corresponding audio file which is stored already and it shuld read that text file. how to do this pl help me..:(
Do you mean there would two files stored, one text and another audio. Once the text file is opened, the corresponding audio file is opened and played?
ya you are right..tat is wat i need..help me..
May be you could do something like this.
1. Maintain a map the text file name is the key, audio file name is the value.
2. Prompt the user to select the text file using filechooser dialog.
3. Match the selected file name with the key in map, fetch the value i.e. the audio file name
4. Play the audio file.
ok thank you i wil try and come back..