Re: [Mesa-dev] [PATCH 2/2] egl: set EGL_BAD_NATIVE_PIXMAP in the copy_buffers fallback

2018-07-05 Thread Eric Engestrom
On Wednesday, 2018-06-27 20:11:18 +0100, Emil Velikov wrote:
> From: Emil Velikov 
> 
> As the spec says:
> 
>   EGL_BAD_NATIVE_PIXMAP is generated if the implementation
>   does not support native pixmaps.
> 
> Signed-off-by: Emil Velikov 

Series is
Reviewed-by: Eric Engestrom 

> ---
> Strictly speaking all the other fallback functions should also set an
> _eglError, although that's outside of the current scope :-)

I expect you're right for at least most of them :)

> ---
>  src/egl/drivers/dri2/egl_dri2_fallbacks.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/src/egl/drivers/dri2/egl_dri2_fallbacks.h 
> b/src/egl/drivers/dri2/egl_dri2_fallbacks.h
> index a664677572e..1482f17d476 100644
> --- a/src/egl/drivers/dri2/egl_dri2_fallbacks.h
> +++ b/src/egl/drivers/dri2/egl_dri2_fallbacks.h
> @@ -25,6 +25,7 @@
>  #ifndef EGL_DRI2_FALLBACKS_INCLUDED
>  #define EGL_DRI2_FALLBACKS_INCLUDED
>  
> +#include "eglcurrent.h"
>  #include "egltypedefs.h"
>  
>  struct wl_buffer;
> @@ -86,7 +87,7 @@ dri2_fallback_copy_buffers(_EGLDriver *drv, _EGLDisplay 
> *dpy,
> _EGLSurface *surf,
> void *native_pixmap_target)
>  {
> -   return EGL_FALSE;
> +   return _eglError(EGL_BAD_NATIVE_PIXMAP, "no support for native pixmaps");
>  }
>  
>  static inline EGLBoolean
> -- 
> 2.18.0
> 
> ___
> mesa-dev mailing list
> mesa-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


[Mesa-dev] [PATCH 2/2] egl: set EGL_BAD_NATIVE_PIXMAP in the copy_buffers fallback

2018-06-27 Thread Emil Velikov
From: Emil Velikov 

As the spec says:

  EGL_BAD_NATIVE_PIXMAP is generated if the implementation
  does not support native pixmaps.

Signed-off-by: Emil Velikov 
---
Strictly speaking all the other fallback functions should also set an
_eglError, although that's outside of the current scope :-)
---
 src/egl/drivers/dri2/egl_dri2_fallbacks.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/egl/drivers/dri2/egl_dri2_fallbacks.h 
b/src/egl/drivers/dri2/egl_dri2_fallbacks.h
index a664677572e..1482f17d476 100644
--- a/src/egl/drivers/dri2/egl_dri2_fallbacks.h
+++ b/src/egl/drivers/dri2/egl_dri2_fallbacks.h
@@ -25,6 +25,7 @@
 #ifndef EGL_DRI2_FALLBACKS_INCLUDED
 #define EGL_DRI2_FALLBACKS_INCLUDED
 
+#include "eglcurrent.h"
 #include "egltypedefs.h"
 
 struct wl_buffer;
@@ -86,7 +87,7 @@ dri2_fallback_copy_buffers(_EGLDriver *drv, _EGLDisplay *dpy,
_EGLSurface *surf,
void *native_pixmap_target)
 {
-   return EGL_FALSE;
+   return _eglError(EGL_BAD_NATIVE_PIXMAP, "no support for native pixmaps");
 }
 
 static inline EGLBoolean
-- 
2.18.0

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev