summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2021-02-24 19:51:40 +0200
committerTim-Philipp Müller <tim@centricular.com>2021-02-25 12:35:08 +0000
commit29a42623f6ec633cbc8a1fc8ce8cd5f5c5bed85c (patch)
tree935d112185c98d0b83388fbe7046d63432588269
parent1806ddd6cf559f187865728987da294e84bfabf5 (diff)
downloadgstreamer-plugins-base-29a42623f6ec633cbc8a1fc8ce8cd5f5c5bed85c.tar.gz
audioaggregator: Log if the sample rate of one sinkpad is not accepted
Otherwise this can silently cause not-negotiated errors without any direct hint about what went wrong. Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1052>
-rw-r--r--gst-libs/gst/audio/gstaudioaggregator.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/gst-libs/gst/audio/gstaudioaggregator.c b/gst-libs/gst/audio/gstaudioaggregator.c
index ac8ee8c6c..f7e006adb 100644
--- a/gst-libs/gst/audio/gstaudioaggregator.c
+++ b/gst-libs/gst/audio/gstaudioaggregator.c
@@ -900,7 +900,8 @@ gst_audio_aggregator_sink_setcaps (GstAudioAggregatorPad * aaggpad,
gboolean downstream_supports_rate = TRUE;
if (!gst_audio_info_from_caps (&info, caps)) {
- GST_WARNING_OBJECT (agg, "Rejecting invalid caps: %" GST_PTR_FORMAT, caps);
+ GST_WARNING_OBJECT (aaggpad, "Rejecting invalid caps: %" GST_PTR_FORMAT,
+ caps);
return FALSE;
}
@@ -933,6 +934,10 @@ gst_audio_aggregator_sink_setcaps (GstAudioAggregatorPad * aaggpad,
if (!downstream_supports_rate || (first_configured_pad
&& info.rate != first_configured_pad->info.rate)) {
+ GST_WARNING_OBJECT (aaggpad,
+ "Sample rate %d can't be configured (downstream supported: %d, configured rate: %d)",
+ info.rate, downstream_supports_rate,
+ first_configured_pad ? first_configured_pad->info.rate : 0);
gst_pad_push_event (GST_PAD (aaggpad), gst_event_new_reconfigure ());
ret = FALSE;
} else {