I want to add the audio stream obtained with getusermedia () to the canvas stream and send it to the remote node ... So I looked up and added addTrack (). But addTrack () is not working properly. I'm running on chrome.
var audioTracks; navigator.getUserMedia({ "audio": true, "video": false }, function (stream) { audioTracks = stream.getAudioTracks()[0]; }, function(error) { console.log(error);}); . . . var sharestream = canvas2.captureStream(25);
This is part of my code. What's wrong? My full webrtc source code works fine, but it does not work with addTrack ().
source share