javascript-media-recorder icon indicating copy to clipboard operation
javascript-media-recorder copied to clipboard

recording all streams in a multiparty call

Open utkarshmaximess opened this issue 8 years ago • 3 comments

Presently your demo only provide for recording one stream(audio+video). But i want to record audio of all parties participating in the conversation.

utkarshmaximess avatar Feb 13 '17 13:02 utkarshmaximess

@utkarshmaximess , so you have streams (audio and video) and you want to record audio tracks from each of callers?

You need to create a MediaStream and attach audio tracks.

var streamForRecord = new MediaStream();

stream.getAudioTracks.forEach(function(track) {
streamForRecord.addTrack(track);
});

var rec1 = new qbMediaRecorder(streamForRecord);

Something like this.

dimaspirit avatar Feb 13 '17 13:02 dimaspirit

Multiple audio tracks added with addTrack (like suggested by dimaspirit) are not supported in webm. Only first added audio track is effectively recorded. I just wanted to record 1 callee video but audio tracks for both 1 caller and 1 callee. Any solution for this?

fabriziozenere avatar Sep 16 '17 21:09 fabriziozenere

You somehow need to convert all audio tracks into one before recording. check out web audio api, https://developer.mozilla.org/en-US/docs/Web/API/ChannelMergerNode

akshay-nm avatar Mar 11 '20 14:03 akshay-nm