Htl5 Voice Recording With Isualization
I'm building a HTML5 software that records a voice and when playing that voice a visualizer should be in action. Here is my code: // variables var leftchannel = []; var rightchanne
Solution 1:
The creation of the volume gain node is done only after the success of getUserMedia, in the success
function.
By the time the code encounter the volume
connect command, volume
is not yet allocated.
You have to 'chain' all your node connection starting from success
.
Quick fix : just put those lines :
// we connect the recorder(node to destination(speakers))
volume.connect(splitter);
splitter.connect(analyser, 0, 0);
splitter.connect(analyser2, 1, 0);
analyser.connect(recorder);
recorder.connect(context.destination);
at the end of the success
function.
Post a Comment for "Htl5 Voice Recording With Isualization"