GstForceKeyUnit in "webrtcbin"

Hi,

As the original discussion is closed at

The remaining question seems to be unclear, whether or not the latest “webrtcbin” or “rtpsession” in 1.22 or 1.24 has ever implemented the RTCP PLI or FIR feedback and issue “GstForceKeyUnit” event to upstream like encoders to generate a new key frame?

If not, so it will leave the logic to the application to publish the event. That would be fine but just need to know it is the case or not. Also it would be grateful if a pointer to the source code would be available to show the implementation if it exists.

Thanks.

Yu

It’s supported in general, but that was always the case. What kind of behaviour are you looking for specifically?

is it possible to share any direct link to the source code in Gstreamer mono repo where the implementation is done? There’s nothing specifically but just want to verify the feature has been supported by GStreamer WebRTC stack., e.g. emitting a key frame event when a PLI or FIR event from a browser (e.g. Chrome).

That’s supported since before WebRTC even existed. Check commit a61bb9e94b23f6dbed0319d6f018a8d857b2edcb.

Thanks for the pointer. It is exactly what I was looking for.

One more question, the key unit request was triggered in the case of GST_RTCP_PSFB_TYPE_PLI only. How about the GST_RTCP_PSFB_TYPE_FIR (Full Intra Request Command)?

It is fine to response to PLI type. Just curious to the FIR type.

Both PLI and FIR are supported and will result in GstForceKeyUnit events being produced.

That was added shortly afterwards. Look at the code / git history, it’s all there :slight_smile: