diff options
Diffstat (limited to 'src/egl/main')
-rw-r--r-- | src/egl/main/eglimage.c | 48 | ||||
-rw-r--r-- | src/egl/main/eglimage.h | 2 |
2 files changed, 50 insertions, 0 deletions
diff --git a/src/egl/main/eglimage.c b/src/egl/main/eglimage.c index fed390a4982..c558f2f02b0 100644 --- a/src/egl/main/eglimage.c +++ b/src/egl/main/eglimage.c @@ -106,6 +106,18 @@ _eglParseImageAttribList(_EGLImageAttribs *attrs, _EGLDisplay *dpy, attrs->DMABufPlanePitches[0].Value = val; attrs->DMABufPlanePitches[0].IsPresent = EGL_TRUE; break; + case EGL_DMA_BUF_PLANE0_MODIFIER_LO_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersLo[0].Value = val; + attrs->DMABufPlaneModifiersLo[0].IsPresent = EGL_TRUE; + break; + case EGL_DMA_BUF_PLANE0_MODIFIER_HI_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersHi[0].Value = val; + attrs->DMABufPlaneModifiersHi[0].IsPresent = EGL_TRUE; + break; case EGL_DMA_BUF_PLANE1_FD_EXT: attrs->DMABufPlaneFds[1].Value = val; attrs->DMABufPlaneFds[1].IsPresent = EGL_TRUE; @@ -118,6 +130,18 @@ _eglParseImageAttribList(_EGLImageAttribs *attrs, _EGLDisplay *dpy, attrs->DMABufPlanePitches[1].Value = val; attrs->DMABufPlanePitches[1].IsPresent = EGL_TRUE; break; + case EGL_DMA_BUF_PLANE1_MODIFIER_LO_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersLo[1].Value = val; + attrs->DMABufPlaneModifiersLo[1].IsPresent = EGL_TRUE; + break; + case EGL_DMA_BUF_PLANE1_MODIFIER_HI_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersHi[1].Value = val; + attrs->DMABufPlaneModifiersHi[1].IsPresent = EGL_TRUE; + break; case EGL_DMA_BUF_PLANE2_FD_EXT: attrs->DMABufPlaneFds[2].Value = val; attrs->DMABufPlaneFds[2].IsPresent = EGL_TRUE; @@ -130,6 +154,18 @@ _eglParseImageAttribList(_EGLImageAttribs *attrs, _EGLDisplay *dpy, attrs->DMABufPlanePitches[2].Value = val; attrs->DMABufPlanePitches[2].IsPresent = EGL_TRUE; break; + case EGL_DMA_BUF_PLANE2_MODIFIER_LO_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersLo[2].Value = val; + attrs->DMABufPlaneModifiersLo[2].IsPresent = EGL_TRUE; + break; + case EGL_DMA_BUF_PLANE2_MODIFIER_HI_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersHi[2].Value = val; + attrs->DMABufPlaneModifiersHi[2].IsPresent = EGL_TRUE; + break; case EGL_DMA_BUF_PLANE3_FD_EXT: if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) err = EGL_BAD_PARAMETER; @@ -148,6 +184,18 @@ _eglParseImageAttribList(_EGLImageAttribs *attrs, _EGLDisplay *dpy, attrs->DMABufPlanePitches[3].Value = val; attrs->DMABufPlanePitches[3].IsPresent = EGL_TRUE; break; + case EGL_DMA_BUF_PLANE3_MODIFIER_LO_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersLo[3].Value = val; + attrs->DMABufPlaneModifiersLo[3].IsPresent = EGL_TRUE; + break; + case EGL_DMA_BUF_PLANE3_MODIFIER_HI_EXT: + if (!dpy->Extensions.EXT_image_dma_buf_import_modifiers) + err = EGL_BAD_PARAMETER; + attrs->DMABufPlaneModifiersHi[3].Value = val; + attrs->DMABufPlaneModifiersHi[3].IsPresent = EGL_TRUE; + break; case EGL_YUV_COLOR_SPACE_HINT_EXT: if (val != EGL_ITU_REC601_EXT && val != EGL_ITU_REC709_EXT && val != EGL_ITU_REC2020_EXT) { diff --git a/src/egl/main/eglimage.h b/src/egl/main/eglimage.h index a909d9b5889..eb66280ff96 100644 --- a/src/egl/main/eglimage.h +++ b/src/egl/main/eglimage.h @@ -73,6 +73,8 @@ struct _egl_image_attribs struct _egl_image_attrib_int DMABufPlaneFds[DMA_BUF_MAX_PLANES]; struct _egl_image_attrib_int DMABufPlaneOffsets[DMA_BUF_MAX_PLANES]; struct _egl_image_attrib_int DMABufPlanePitches[DMA_BUF_MAX_PLANES]; + struct _egl_image_attrib_int DMABufPlaneModifiersLo[DMA_BUF_MAX_PLANES]; + struct _egl_image_attrib_int DMABufPlaneModifiersHi[DMA_BUF_MAX_PLANES]; struct _egl_image_attrib_int DMABufYuvColorSpaceHint; struct _egl_image_attrib_int DMABufSampleRangeHint; struct _egl_image_attrib_int DMABufChromaHorizontalSiting; |