audiocontext

How to play wav audio byte array via javascript/html5?

会有一股神秘感。 提交于 2019-11-26 13:59:41
问题 I'm using the following method to play a byte array containing wav data. The function is being called from a GWT project. This function plays back sound, but it sounds like some kind of Hellish monster. The sample rate is definitely correct (the sound is being generated by neospeech) and I've tried all kinds of values for numberOfSamples, which just seems to represent how long the audio data is. A value greater than 30000 for numberOfSamples will play the audio file's full length but it is