Auto Video Degrade/Restore
Sometimes people have bad internet connections but everyone deserves a good meeting.
When the network is too slow to support audio and video conversations together, the 100ms SDK can automatically turn off downloading other peer's videos, which may improve the audio quality and avoid disconnections.
If the network quality improves, the videos will be restored automatically as well.
To turn on subscribe degradation in your room, open the templates in the dashboard and enable it for roles there. Here's more information about templates.
Responding in the app
HMSVideoTracks, within the
HMSPeer's have a variable called
isDegraded is true, in the UI, treat it as if the video is turned off. If the UI is not changed, the video tile will appear black.
An important note here is that
removeSink still need to be called on the video even if it's degraded. If this isn't done:
- Subscribe degradation will not know how many videos are supposed to be shown and videos may degrade, never to be restored again.
- In the case where a video was on screen and then was degraded, remove sink may not be called for it depending on your code. If this were to happen and the video was restored later you would end up downloading multiple more videos than what are being shown.