Revert "glupload: Fix caps query with no filter"
authorJan Schmidt <jan@centricular.com>
Fri, 1 Jul 2022 13:57:08 +0000 (23:57 +1000)
committerJan Schmidt <jan@centricular.com>
Fri, 1 Jul 2022 14:05:53 +0000 (00:05 +1000)
This reverts commit 6f9ae5d7580763b5d18badb76f2166ff0012886a.

The _transform_caps() function can't tell the difference
between the caller wanting to know the output caps
for the current method, or all possible output caps. If
it includes caps for all possible methods, glupload can
end up negotiating and sending the wrong output caps
downstream.

Partially reverts !2687
Fixes #1310

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2699>

subprojects/gst-plugins-base/gst-libs/gst/gl/gstglupload.c

index 96d2880..8cd09f6 100644 (file)
@@ -2358,12 +2358,7 @@ gst_gl_upload_transform_caps (GstGLUpload * upload, GstGLContext * context,
   GstCaps *result, *tmp;
   gint i;
 
-  /* If (and only if) there is an upstream filter, we can
-   * save some time by first checking if the configured upload method
-   * generates intersecting caps. If there's no filter, or no
-   * intersection we need to generate a full set of caps from all
-   * uploaders for upstream to choose from */
-  if (upload->priv->method && filter != NULL) {
+  if (upload->priv->method) {
     tmp = upload->priv->method->transform_caps (upload->priv->method_impl,
         context, direction, caps);
     if (tmp) {