From abd61732bf8076743e9cfb6a43ee89e378ce8fd7 Mon Sep 17 00:00:00 2001 From: Mathieu Duponchelle Date: Thu, 9 Dec 2021 03:00:56 +0100 Subject: [PATCH] webrtcbin: bind transceiver's fec-percentage to encoder percentage Allows for dynamic control of the applied FEC overhead Part-of: --- subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c b/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c index 0e7c17e..917a982 100644 --- a/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c +++ b/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c @@ -4374,6 +4374,9 @@ _build_fec_encoder (GstWebRTCBin * webrtc, WebRTCTransceiver * trans) g_object_set (fecenc, "pt", ulpfec_pt, "percentage", trans->fec_percentage, NULL); + g_object_bind_property (rtp_trans, "fec-percentage", fecenc, "percentage", + G_BINDING_BIDIRECTIONAL); + if (caps && !gst_caps_is_empty (caps)) { const GstStructure *s = gst_caps_get_structure (caps, 0); const gchar *media = gst_structure_get_string (s, "media"); -- 2.7.4