mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-19 00:01:23 +00:00
glfilter: pass through the allocation query when in passthrough mode
Otherwise two GL elements on either side will fail to use the same GL context.
This commit is contained in:
parent
a2bd2ce83b
commit
720405b561
1 changed files with 10 additions and 6 deletions
|
@ -215,25 +215,29 @@ gst_gl_filter_query (GstBaseTransform * trans, GstPadDirection direction,
|
|||
GstQuery * query)
|
||||
{
|
||||
GstGLFilter *filter;
|
||||
gboolean res;
|
||||
|
||||
filter = GST_GL_FILTER (trans);
|
||||
|
||||
switch (GST_QUERY_TYPE (query)) {
|
||||
case GST_QUERY_ALLOCATION:
|
||||
{
|
||||
if (direction == GST_PAD_SINK
|
||||
&& gst_base_transform_is_passthrough (trans))
|
||||
return gst_pad_peer_query (GST_BASE_TRANSFORM_SRC_PAD (trans), query);
|
||||
break;
|
||||
}
|
||||
case GST_QUERY_CONTEXT:
|
||||
{
|
||||
res = gst_gl_handle_context_query ((GstElement *) filter, query,
|
||||
return gst_gl_handle_context_query ((GstElement *) filter, query,
|
||||
&filter->display);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
res =
|
||||
GST_BASE_TRANSFORM_CLASS (parent_class)->query (trans, direction,
|
||||
query);
|
||||
break;
|
||||
}
|
||||
|
||||
return res;
|
||||
return GST_BASE_TRANSFORM_CLASS (parent_class)->query (trans, direction,
|
||||
query);;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in a new issue