<!DOCTYPE html><html><head><title></title><style type="text/css">p.MsoNormal,p.MsoNoSpacing{margin:0}
p.MsoNormal,p.MsoNoSpacing{margin:0}</style></head><body><div>Hi,<br></div><div><br></div><div>I noticed that with the 1.18 release it is possible to get the transport-wide congestion control (twcc) using webrtcbin. As far as I can understand, this means that Chrome will send a RTP header extension with a transport-wide sequence number to GStreamer, and GStreamer will send an RTCP feedback packet of type GST_RTCP_RTPFB_TYPE_TWCC=15 with FCI content like packet status chunks and receive delta. Then it should be possible to get the TWCC stats in GStreamer with some code like this:<br></div><div><br></div><div><span style="font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;-webkit-text-stroke-width:0px;text-decoration:none;color:rgb(0, 0, 0);background-color:rgb(255, 255, 255);float:none;display:inline !important;"><span class="font" style="font-family:Verdana, Geneva, Helvetica, Arial, sans-serif;"><span class="size" style="font-size:13.4399995803833px;">GstElement* rtpbin = gst_bin_get_by_name(GST_BIN(webrtcbin), "rtpbin");</span></span></span><br></div><div><span style="font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;-webkit-text-stroke-width:0px;text-decoration:none;color:rgb(0, 0, 0);background-color:rgb(255, 255, 255);float:none;display:inline !important;"><span class="font" style="font-family:Verdana, Geneva, Helvetica, Arial, sans-serif;"><span class="size" style="font-size:13.4399995803833px;">g_signal_emit_by_name(rtpbin, "get-session", 0, &session);</span></span></span><br></div><div><span style="font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;-webkit-text-stroke-width:0px;text-decoration:none;color:rgb(0, 0, 0);background-color:rgb(255, 255, 255);float:none;display:inline !important;"><span class="font" style="font-family:Verdana, Geneva, Helvetica, Arial, sans-serif;"><span class="size" style="font-size:13.4399995803833px;">g_object_get(G_OBJECT(session), "twcc-stats", &twcstats, NULL);</span></span></span><br></div><div><br></div><div>My question: Is it only possible to make this work with Chrome so far, or would this also work with a client that uses the native WebRTC code (e.g. Android) ? My goal is to stream to an Android app from a server application using GStreamer webrtcbin and get the twcc-stats on the sender-side so that I can apply some bandwidth adaptation logic according to congestion level and jitter. It seems that the receive bitrate statistic from from twcc-stats is a good candidate for early detection of congestion.<br></div><div><br></div><div>Thanks.<br></div><div>Serhan<br></div><div> <br></div><div id="sig67116920"><div class="signature">-- <br></div><div class="signature"> Serhan Gül<br></div><div class="signature"> <a href="mailto:serhan%40fastmail.com">serhan@fastmail.com</a><br></div><div class="signature"><br></div></div><div><br></div></body></html>