[yocto] [meta-raspberrypi][PATCH 2/2] userland: Fix tearing effect seen with wayland compositors
Khem Raj
raj.khem at gmail.com
Tue Mar 29 20:44:31 PDT 2016
Introduce EGL flush in few more places
Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
...Fix-for-framerate-with-nested-composition.patch | 46 ++++++++++++++++++----
1 file changed, 39 insertions(+), 7 deletions(-)
diff --git a/recipes-graphics/userland/userland/0013-Fix-for-framerate-with-nested-composition.patch b/recipes-graphics/userland/userland/0013-Fix-for-framerate-with-nested-composition.patch
index 6377e31..2fa9d66 100644
--- a/recipes-graphics/userland/userland/0013-Fix-for-framerate-with-nested-composition.patch
+++ b/recipes-graphics/userland/userland/0013-Fix-for-framerate-with-nested-composition.patch
@@ -1,20 +1,39 @@
-From 7f424ce48f6c14118aea2ab770b3bbf87e1f0393 Mon Sep 17 00:00:00 2001
+From e5affc4ff145eedf61e2625a8919622c92d0b8ba Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem at gmail.com>
-Date: Thu, 24 Mar 2016 14:30:58 -0700
-Subject: [PATCH 13/13] Fix for framerate with nested composition
+Date: Tue, 29 Mar 2016 20:38:30 -0700
+Subject: [PATCH 13/14] Fix for framerate with nested composition
frame rate appears irregular and lower than expected when using nested composition.
Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
- interface/khronos/egl/egl_client.c | 1 +
- 1 file changed, 1 insertion(+)
+ interface/khronos/egl/egl_client.c | 9 ++++++++-
+ 1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
-index 024f3ed..95bb581 100644
+index 024f3ed..d8a007c 100644
--- a/interface/khronos/egl/egl_client.c
+++ b/interface/khronos/egl/egl_client.c
-@@ -2360,6 +2360,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+@@ -2342,6 +2342,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+ surface->back_wl_buffer = buffer;
+ }
+
++ glFlush();
++ glFinish();
++
+ RPC_CALL7(eglIntSwapBuffers_impl,
+ thread,
+ EGLINTSWAPBUFFERS_ID_V2,
+@@ -2353,6 +2356,8 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+ RPC_UINT(khrn_platform_get_window_position(surface->win)),
+ RPC_INT(surface->back_wl_buffer->resource));
+
++ RPC_FLUSH(thread);
++
+ surface->front_wl_buffer->in_use = 1;
+ wl_surface_attach(wl_egl_window->wl_surface,
+ surface->front_wl_buffer->wl_buffer,
+@@ -2360,10 +2365,11 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
wl_surface_damage(wl_egl_window->wl_surface, 0, 0,
surface->width, surface->height);
wl_surface_commit(wl_egl_window->wl_surface);
@@ -22,6 +41,19 @@ index 024f3ed..95bb581 100644
while(ret != -1 && surface->back_wl_buffer->in_use)
ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
+- } else
++ } else {
+ #endif
+ RPC_CALL6(eglIntSwapBuffers_impl,
+ thread,
+@@ -2376,6 +2382,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+ RPC_UINT(khrn_platform_get_window_position(surface->win)));
+
+ RPC_FLUSH(thread);
++ }
+
+ #ifdef ANDROID
+ CLIENT_UNLOCK();
--
2.7.4
--
2.7.4
More information about the yocto
mailing list