From 48a74da64eac1a593116694f8c6ca299058f6304 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Calvi=C3=B1o=20S=C3=A1nchez?= Date: Thu, 3 Feb 2022 22:46:53 +0100 Subject: Update connections rather than create new ones on "negotiationneeded" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When an offer is requested to the HPB the old connection is stopped and a new one is created. If the HPB has support for updating the subscribers this is now used instead when negotiation is needed, as this prevents the existing connection (and thus the media) to be interrupted during the renegotiation. Signed-off-by: Daniel Calviño Sánchez --- src/utils/signaling.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/utils/signaling.js') diff --git a/src/utils/signaling.js b/src/utils/signaling.js index 6b6fbab32..c0d1fbb52 100644 --- a/src/utils/signaling.js +++ b/src/utils/signaling.js @@ -1292,7 +1292,7 @@ Signaling.Standalone.prototype.processRoomParticipantsEvent = function(data) { } } -Signaling.Standalone.prototype.requestOffer = function(sessionid, roomType) { +Signaling.Standalone.prototype.requestOffer = function(sessionid, roomType, sid = undefined) { if (!this.hasFeature('mcu')) { console.warn("Can't request an offer without a MCU.") return @@ -1302,7 +1302,7 @@ Signaling.Standalone.prototype.requestOffer = function(sessionid, roomType) { // Got a user object. sessionid = sessionid.sessionId || sessionid.sessionid } - console.debug('Request offer from', sessionid) + console.debug('Request offer from', sessionid, sid) this.doSend({ type: 'message', message: { @@ -1313,6 +1313,7 @@ Signaling.Standalone.prototype.requestOffer = function(sessionid, roomType) { data: { type: 'requestoffer', roomType, + sid, }, }, }) -- cgit v1.2.3