From 253ee75a728513cf29e5da9fd27dbcdd93646946 Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Tue, 15 Mar 2022 17:01:59 +0530 Subject: [PATCH] webrtcbin: Warn when offer didn't intersect with transceiver caps We were silently falling back to creating a recvonly offer if the caps didn't intersect. Part-of: --- subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c b/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c index 22f7704..be0d77b 100644 --- a/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c +++ b/subprojects/gst-plugins-bad/ext/webrtc/gstwebrtcbin.c @@ -4064,7 +4064,7 @@ _create_answer_task (GstWebRTCBin * webrtc, const GstStructure * options, goto rejected; } - GST_TRACE_OBJECT (webrtc, "trying to compare %" GST_PTR_FORMAT + GST_LOG_OBJECT (webrtc, "trying to compare %" GST_PTR_FORMAT " and %" GST_PTR_FORMAT, offer_caps, trans_caps); /* FIXME: technically this is a little overreaching as some fields we @@ -4095,6 +4095,8 @@ _create_answer_task (GstWebRTCBin * webrtc, const GstStructure * options, /* if no transceiver, then we only receive that stream and respond with * the intersection with the transceivers codec preferences caps */ answer_dir = GST_WEBRTC_RTP_TRANSCEIVER_DIRECTION_RECVONLY; + GST_WARNING_OBJECT (webrtc, "did not find compatible transceiver for " + "offer caps %" GST_PTR_FORMAT ", will only receive", offer_caps); } if (!rtp_trans) { -- 2.7.4