mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-27 03:23:16 +00:00
pulse: Get caps correctly on pad block
Instead of always going upstream, we should first see if already got caps from a setcaps() call. https://bugzilla.gnome.org/show_bug.cgi?id=661262
This commit is contained in:
parent
e9ad06e202
commit
a7790efd04
1 changed files with 8 additions and 1 deletions
|
@ -653,7 +653,14 @@ proxypad_blocked_cb (GstPad * pad, gboolean blocked, gpointer data)
|
|||
|
||||
if (!pbin->format_lost) {
|
||||
sinkpad = gst_element_get_static_pad (GST_ELEMENT (pbin->psink), "sink");
|
||||
caps = gst_pad_get_caps_reffed (pad);
|
||||
|
||||
if (GST_PAD_CAPS (pbin->sinkpad)) {
|
||||
/* See if we already got caps on our sinkpad */
|
||||
caps = gst_caps_ref (GST_PAD_CAPS (pbin->sinkpad));
|
||||
} else {
|
||||
/* We haven't, so get caps from upstream */
|
||||
caps = gst_pad_get_caps_reffed (pad);
|
||||
}
|
||||
|
||||
if (gst_pad_accept_caps (sinkpad, caps)) {
|
||||
if (pbin->dbin2) {
|
||||
|
|
Loading…
Reference in a new issue