gl: eglExportDMABUFImageQueryMESA expects modifiers to be an array

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8672>
This commit is contained in:
Víctor Manuel Jáquez Leal 2025-03-24 16:53:46 +01:00 committed by GStreamer Marge Bot
parent 1ea4632668
commit 146b49fd9e

View File

@ -1043,7 +1043,7 @@ gst_egl_image_export_dmabuf (GstEGLImage * image, int *fd, gint * stride,
EGLint egl_stride = 0;
EGLint egl_offset = 0;
int fourcc;
EGLuint64KHR modifier;
EGLuint64KHR modifier[GST_VIDEO_MAX_PLANES] = { 0, };
gst_eglExportDMABUFImageQueryMESA =
gst_gl_context_get_proc_address (image->context,
@ -1069,7 +1069,7 @@ gst_egl_image_export_dmabuf (GstEGLImage * image, int *fd, gint * stride,
gst_object_unref (display_egl);
if (!gst_eglExportDMABUFImageQueryMESA (egl_display, image->image,
&fourcc, &num_planes, &modifier))
&fourcc, &num_planes, modifier))
return FALSE;
/* Don't allow multi-plane dmabufs */
@ -1077,7 +1077,7 @@ gst_egl_image_export_dmabuf (GstEGLImage * image, int *fd, gint * stride,
return FALSE;
/* FIXME We don't support modifiers */
if (modifier != DRM_FORMAT_MOD_LINEAR)
if (modifier[0] != DRM_FORMAT_MOD_LINEAR)
return FALSE;
if (!gst_eglExportDMABUFImageMESA (egl_display, image->image, &egl_fd,
@ -1086,7 +1086,7 @@ gst_egl_image_export_dmabuf (GstEGLImage * image, int *fd, gint * stride,
GST_DEBUG_OBJECT (image->context, "Export DMABuf with fourcc %"
GST_FOURCC_FORMAT ", modififers %" G_GUINT64_FORMAT
", stride %i and offset %i", GST_FOURCC_ARGS (fourcc), modifier,
", stride %i and offset %i", GST_FOURCC_ARGS (fourcc), modifier[0],
egl_stride, egl_offset);
*fd = egl_fd;