From 21a27fa9a0682c8903a4a3a530261dbcdb515948 Mon Sep 17 00:00:00 2001 From: Pierre Lespagnol <pierre.lespagnol@savoirfairelinux.com> Date: Tue, 26 Jan 2021 15:25:42 -0500 Subject: [PATCH] conference: renegotiate the remaining call after conference Otherwise the resolution is not updated and the remaining call keep the conference resolution. Gitlab: #389 Change-Id: Ib7a3880fceb1d1c0eafa3bac8aa0830c29c437d7 --- src/conference.cpp | 6 ++++++ src/media/video/video_rtp_session.cpp | 8 -------- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/src/conference.cpp b/src/conference.cpp index 915c4197ea..3348f22dba 100644 --- a/src/conference.cpp +++ b/src/conference.cpp @@ -135,6 +135,12 @@ Conference::~Conference() call->sendTextMessage(std::map<std::string, std::string> {{"application/confInfo+json", "[]"}}, account->getFromUri()); + + // Trigger the SIP negotiation to update the resolution for the remaining call + // ideally this sould be done without renegotiation + call->switchInput( + Manager::instance().getVideoManager().videoDeviceMonitor.getMRLForDefaultDevice()); + // Continue the recording for the call if the conference was recorded if (this->isRecording()) { JAMI_DBG("Stop recording for conf %s", getConfID().c_str()); diff --git a/src/media/video/video_rtp_session.cpp b/src/media/video/video_rtp_session.cpp index 88d7c31764..8ad2d204a0 100644 --- a/src/media/video/video_rtp_session.cpp +++ b/src/media/video/video_rtp_session.cpp @@ -394,14 +394,6 @@ VideoRtpSession::exitConference() videoMixer_.reset(); } - // videoLocal_ is reset when a conference is created (only mixer need videoInput) - // when the conference is removed, we need to set videoLocal_ for the remaining call - if (!videoLocal_) - videoLocal_ = getVideoCamera(); - - if (videoLocal_) - videoLocal_->attach(sender_.get()); - conference_ = nullptr; } -- GitLab