hello guys
Am developing a text-to-speech for my own language in java (its my final project which is not developed before, therefor I could NOT use built-in classes). I can recognize the diphones for input text, for playing: I place the diphones in an array, after the input text analysis completed I play the audio files (which are in ogg format) according to the diphones in the array one by one. what I want to ask is: what do you think about this way for playing separate diphones? and what to do to make it smoother because its really not smooth (there is a big gap between playing one file and next one)
Please UseRealWords. I imagine not many people know what the abbreviation TTS stands for, so it's better to just write text-to-speech.
As for your problem, I haven't really worked with audio in Java that much, but I imagine that instead of playing separate files, it's better to buffer the files well before they're about to be played, or create an entire new file consisting of the phones and diphones for the part of speech that you want to play.
thanks for reply...
I don't think it's possible to merge all files, but buffering them well maybe.
but I'm seeking for better approach
thank you again.
sorry I didn't mean it's not good
but I personally didn't tried it before so I don't know how much effective it will be.
my audio files are in a package for example sounds and I just give the path and play
better say I don't know how exactly to buffer them!!!
Exactly, that's the problem. You're loading the files one at a time, so there's a gap between two fragments when the program has to load the next file. If the sounds are buffered, they can start playing immediately after the previous sound ends.
Now, if you show us how you're currently playing the sound fragments, maybe we can show you how to improve smooth playback.