Skip to content

Conversation

@backportbot-nextcloud
Copy link

backport of #6862

danxuliu added 10 commits April 29, 2022 09:50
If the HPB is used it is enough to reconnect only with the receiver peer
that needs a negotiation rather than forcing a full reconnection.

Signed-off-by: Daniel Calviño Sánchez <[email protected]>
Before a negotiation needed event in a receiver Peer caused a forced
reconnection, so the whole call was reset. Now only the affected Peer
object is reset, so the simulcast levels previously set need to be set
again on the new Peer object.

Signed-off-by: Daniel Calviño Sánchez <[email protected]>
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 <[email protected]>
Remote video can be blocked and allowed again by adjusting the direction
of the video transceiver of RTCPeerConnections, which triggers a
"negotiationneeded" event. When a negotiation is needed a new exchange
of offers and answers needs to be made between the peers.

Renegotiations need to be supported by both peers, so currently this is
available only with the HPB, and only on versions that support the
"update-sdp" feature.

When the HPB is being used "negotiationneeded" event causes a new offer
to be requested, which will be an update if the HPB supports it. Updates
rather than new connections are needed to prevent an audio interruption
while the connection changes.

Signed-off-by: Daniel Calviño Sánchez <[email protected]>
If the connection transitions to "disconnected" (or was disconnected
before starting the renegotiation) the UI will wrongly show the message
about reconnecting due to connection problems.

I have not found an easy way to solve this, as it would require to keep
track of whether a renegotiation started due to handling the
"negotiationneeded" event or something else (and, in the future, once
renegotiations are implemented also without HPB, it should be necessary
to know too if the offer was sent by the remote peer for other reasons).
Due to this, for now a slightly misleading message will be shown if the
connection is updated while "disconnected".

Signed-off-by: Daniel Calviño Sánchez <[email protected]>
A remote video is not needed when it was explicitly disabled by the
local user (independently of whether it is enabled by the remote
participant) or when it is not visible.

Signed-off-by: Daniel Calviño Sánchez <[email protected]>
Now the remote videos will be blocked when not needed, that is, when
explicitly disabled by the local user or when not visible.

Signed-off-by: Daniel Calviño Sánchez <[email protected]>
The "talk:video:toggled" event is triggered by VideoBottomBar and only
handled in CallView to enable or disable the remote video. As the
handling just calls a method in the RemoteVideoBlocker this can be
directly done in the VideoBottomBar instead.

Signed-off-by: Daniel Calviño Sánchez <[email protected]>
@backportbot-nextcloud backportbot-nextcloud bot added feature: call 📹 Voice and video calls feature: frontend 🖌️ "Web UI" client feature: signaling 📶 Internal and external signaling backends feature: WebRTC 🚡 WebRTC connection between browsers and/or mobile clients labels Apr 29, 2022
@backportbot-nextcloud backportbot-nextcloud bot added this to the 💛 Next RC (24) milestone Apr 29, 2022
Copy link
Member

@danxuliu danxuliu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and works 👍

@nickvergessen nickvergessen merged commit 87d8126 into stable24 Apr 29, 2022
@nickvergessen nickvergessen deleted the backport/6862/stable24 branch April 29, 2022 10:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature: call 📹 Voice and video calls feature: frontend 🖌️ "Web UI" client feature: signaling 📶 Internal and external signaling backends feature: WebRTC 🚡 WebRTC connection between browsers and/or mobile clients

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants