我想記錄每個新的會話/用戶添加到RTCMultiConnection。
我使用下面的演示網址應用 https://rtcmulticonnection.herokuapp.com/demos/Audio+Video+TextChat+FileSharing.htmlstartRecording使用RecordRTC與RTCMultiConnection不工作
我現在已經增加了以下CDN參考代碼。 https://cdn.webrtc-experiment.com/RecordRTC.js
這是我正在使用的代碼,但connection.streams[event.streamid].startRecording();
不起作用。
// ..................RTCMultiConnection Code............. // ...................................................... var connection = new RTCMultiConnection(); var btnStopRec = document.getElementById("btnStopRecording"); connection.socketURL = 'https://rtcmulticonnection.herokuapp.com:443/'; connection.enableFileSharing = true; connection.session = { audio: true, video: true, data: true, }; connection.sdpConstraints.mandatory = { OfferToReceiveAudio: true, OfferToReceiveVideo: true, }; connection.onstream = function (event) { document.body.appendChild(event.mediaElement); console.log("stream recording starts") connection.streams[event.streamid].startRecording(); console.log("stream recording started") }
謝謝兄弟... tusee大幹草...... :) –