mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-20 00:31:13 +00:00
glupload: dmabuf: only accept uploads to external-oes if supported by the context
This keeps the DirectDmabufExternal uploader from accepting buffers if texture-target=external-oes is not supported by the GL context.
This commit is contained in:
parent
0200175d97
commit
40773e9c91
1 changed files with 5 additions and 0 deletions
|
@ -633,6 +633,11 @@ _dma_buf_upload_accept (gpointer impl, GstBuffer * buffer, GstCaps * in_caps,
|
||||||
"EGL_KHR_image_base"))
|
"EGL_KHR_image_base"))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
if (dmabuf->target == GST_GL_TEXTURE_TARGET_EXTERNAL_OES &&
|
||||||
|
!gst_gl_context_check_feature (dmabuf->upload->context,
|
||||||
|
"GL_OES_EGL_image_external"))
|
||||||
|
return FALSE;
|
||||||
|
|
||||||
/* This will eliminate most non-dmabuf out there */
|
/* This will eliminate most non-dmabuf out there */
|
||||||
if (!gst_is_dmabuf_memory (gst_buffer_peek_memory (buffer, 0)))
|
if (!gst_is_dmabuf_memory (gst_buffer_peek_memory (buffer, 0)))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
Loading…
Reference in a new issue