From f9bf9133ccc3764dc38f6359a26004e12b888af3 Mon Sep 17 00:00:00 2001 From: Emil Velikov Date: Mon, 11 May 2015 23:43:47 +0100 Subject: [PATCH] egl: fix the EGL_MESA_image_dma_buf_export header declarations MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Similar to other EGL extensions - guard the function prototypes by EGL_EGLEXT_PROTOTYPES as the libEGL library does (should) not provide the symbols statically. Instead users should call eglGetProcAddress, which returns the function pointer. The latter of which was missing the type declaration (typedef). Cc: Dave Airlie Cc: Marc-André Lureau Signed-off-by: Emil Velikov Reviewed-by: Marek Olšák Reviewed-by: Chad Versace --- include/EGL/eglmesaext.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/EGL/eglmesaext.h b/include/EGL/eglmesaext.h index 27cf7ebe7e7..40a60ec35ed 100644 --- a/include/EGL/eglmesaext.h +++ b/include/EGL/eglmesaext.h @@ -127,9 +127,15 @@ typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSREGIONNOK) (EGLDisplay dpy, EG #if KHRONOS_SUPPORT_INT64 #ifndef EGL_MESA_image_dma_buf_export #define EGL_MESA_image_dma_buf_export 1 +#ifdef EGL_EGLEXT_PROTOTYPES EGLAPI EGLBoolean EGLAPIENTRY eglExportDMABUFImageQueryMESA (EGLDisplay dpy, EGLImageKHR image, EGLint *fourcc, EGLint *nplanes, EGLuint64KHR *modifiers); EGLAPI EGLBoolean EGLAPIENTRY eglExportDMABUFImageMESA (EGLDisplay dpy, EGLImageKHR image, int *fds, EGLint *strides, EGLint *offsets); #endif +#endif + +typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDMABUFIMAGEQUERYMESA) (EGLDisplay dpy, EGLImageKHR image, EGLint *fourcc, EGLint *nplanes, EGLuint64KHR *modifiers); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDMABUFIMAGEMESA) (EGLDisplay dpy, EGLImageKHR image, int *fds, EGLint *strides, EGLint *offsets); + #endif #ifdef __cplusplus } -- 2.30.2