On Tue, Jan 05, 2010 at 11:01:37PM +0800, Chia-I Wu wrote:
> This patch fixes EGL breakage after -fvisibility=hidden.  Please check.
The last chunk of the patch removes an unnecessary call to
_eglSwapBuffers in egl_softpipe, which is no longer visible from the
driver.  It was left out when the patch was commited.

Re-submit the last chunk.

-- 
Regards,
olv
>From 9f7d4a1f1b87fe8cb384d488c5875c35cab22fd5 Mon Sep 17 00:00:00 2001
From: Chia-I Wu <olva...@gmail.com>
Date: Tue, 5 Jan 2010 21:39:15 +0800
Subject: [PATCH] egl_softpipe: Remove the unnecessary call to _eglSwapBuffers.

The call to _eglSwapBuffers is unnecessary, and the function is missing
when -fvisibility=hidden.  Also remove the extraneous braces and indent
the block.
---
 src/gallium/winsys/egl_xlib/egl_xlib.c |   22 ++++++++--------------
 1 files changed, 8 insertions(+), 14 deletions(-)

diff --git a/src/gallium/winsys/egl_xlib/egl_xlib.c b/src/gallium/winsys/egl_xlib/egl_xlib.c
index 599973c..420dccc 100644
--- a/src/gallium/winsys/egl_xlib/egl_xlib.c
+++ b/src/gallium/winsys/egl_xlib/egl_xlib.c
@@ -751,24 +751,18 @@ xlib_eglReleaseTexImage(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSurface *surface,
 static EGLBoolean
 xlib_eglSwapBuffers(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSurface *draw)
 {
-   /* error checking step: */
-   if (!_eglSwapBuffers(drv, dpy, draw))
-      return EGL_FALSE;
-
-   {
-      struct xlib_egl_surface *xsurf = lookup_surface(draw);
-      struct pipe_winsys *pws = xsurf->winsys;
-      struct pipe_surface *psurf;
+   struct xlib_egl_surface *xsurf = lookup_surface(draw);
+   struct pipe_winsys *pws = xsurf->winsys;
+   struct pipe_surface *psurf;
 
-      st_get_framebuffer_surface(xsurf->Framebuffer, ST_SURFACE_BACK_LEFT,
-                                 &psurf);
+   st_get_framebuffer_surface(xsurf->Framebuffer, ST_SURFACE_BACK_LEFT,
+         &psurf);
 
-      st_notify_swapbuffers(xsurf->Framebuffer);
+   st_notify_swapbuffers(xsurf->Framebuffer);
 
-      display_surface(pws, psurf, xsurf);
+   display_surface(pws, psurf, xsurf);
 
-      check_and_update_buffer_size(xsurf);
-   }
+   check_and_update_buffer_size(xsurf);
 
    return EGL_TRUE;
 }
-- 
1.6.4.3

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Mesa3d-dev mailing list
Mesa3d-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev

Reply via email to