selkies-project / selkies-gstreamer

Open-Source Low-Latency Accelerated Linux WebRTC HTML5 Remote Desktop Streaming Platform for Self-Hosting, Containers, Kubernetes, or Cloud/HPC
https://selkies-project.github.io/selkies-gstreamer/
Mozilla Public License 2.0
381 stars 49 forks source link

Implement rtpgccbwe #143

Closed ehfd closed 7 months ago

ehfd commented 7 months ago

Reference the issue numbers and reviewers Use # and @ to tag issues and reviewers.

Issue: #78

Explain relevant issues and how this pull request solves them A clear and concise description of the pull request. Ex. This pull request addresses issue # by [...]

Fixes #78

Describe the changes in code and its dependencies and justify that they work as intended after testing A clear and concise description of what you have changed. Please confirm that the pull request does not break this project by testing it in depth.

Translation of https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/blob/main/net/webrtc/src/webrtcsink/imp.rs for twcc and rtpgccbwe. Further analysis of the webrtcsink code is required.

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered other than this pull request, if applicable.

Additional context Add any other context or screenshots about the pull request here. Please describe whether you are willing to provide funding, as this will greatly accelerate your request.

ehfd commented 7 months ago

Current state: rtpgccbwe is implemented but doesn't work due to the lack of twcc. Need to implement twcc by translating https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/blob/main/net/webrtc/src/webrtcsink/imp.rs.

ehfd commented 7 months ago

twcc was implemented, but a few issues remain:

Otherwise, the fix for video is beautiful even in very high bitrates. Nearly no stutter.

ehfd commented 7 months ago

Quality improved by adding FEC for audio and not using FEC for video (NACK/PLI/FIR is sufficient and FEC makes video inefficient).

Sustained stable bandwidth up to 30-40 mbps is achieved.