gstsink: Do not advertise dmabufs with no formats
We return an empty format list when dmabufs aren't supported, not NULL. And the sink was treating the empty format list by setting no fourccs on the caps, which GStreamer conveniently interpreted as "any", not as "none".
This commit is contained in:
@@ -219,7 +219,7 @@ gtk_gst_sink_get_caps (GstBaseSink *bsink,
|
||||
{
|
||||
GdkDmabufFormats *formats = gdk_display_get_dmabuf_formats (self->gdk_display);
|
||||
|
||||
if (formats)
|
||||
if (formats && gdk_dmabuf_formats_get_n_formats (formats) > 0)
|
||||
{
|
||||
tmp = gst_caps_from_string (DMABUF_TEXTURE_CAPS);
|
||||
add_drm_formats_and_modifiers (tmp, formats);
|
||||
|
Reference in New Issue
Block a user