Skip to content

Instantly share code, notes, and snippets.

@kypflug
Created September 1, 2015 22:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kypflug/4a6fda600b5963b838a6 to your computer and use it in GitHub Desktop.
Save kypflug/4a6fda600b5963b838a6 to your computer and use it in GitHub Desktop.
mySignaller.onRemoteParams = function(params) {
// The responder answers with its preferences, parameters and capabilities
// Derive the send and receive parameters.
var audioSendParams = myCapsToSendParams(sendAudioCaps, params.recvAudioCaps);
var videoSendParams = myCapsToSendParams(sendVideoCaps, params.recvVideoCaps);
var audioRecvParams = myCapsToRecvParams(recvAudioCaps, params.sendAudioCaps);
var videoRecvParams = myCapsToRecvParams(recvVideoCaps, params.sendVideoCaps);
iceTr.start(iceGathr, params.ice, RTCIceRole.controlling);
dtlsTr.start(params.dtls);
audioSender.send(audioSendParams);
videoSender.send(videoSendParams);
audioReceiver.receive(audioRecvParams);
videoReceiver.receive(videoRecvParams);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment