[PATCH] gl-renderer: emit frame_signal after eglSwapBuffers

Fabien Dessenne fabien.dessenne at st.com
Fri Aug 12 12:11:40 UTC 2016


Emit frame_signal at the end of the GL renderer processing, so the
frame_signal clients are informed after the buffer is actually updated.

Signed-off-by: Fabien Dessenne <fabien.dessenne at st.com>
---
 libweston/gl-renderer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libweston/gl-renderer.c b/libweston/gl-renderer.c
index d624453..f4d4a5e 100644
--- a/libweston/gl-renderer.c
+++ b/libweston/gl-renderer.c
@@ -1138,7 +1138,6 @@ gl_renderer_repaint_output(struct weston_output *output,
 	draw_output_borders(output, border_damage);
 
 	pixman_region32_copy(&output->previous_damage, output_damage);
-	wl_signal_emit(&output->frame_signal, output);
 
 	if (gr->swap_buffers_with_damage) {
 		pixman_region32_init(&buffer_damage);
@@ -1185,6 +1184,7 @@ gl_renderer_repaint_output(struct weston_output *output,
 	}
 
 	go->border_status = BORDER_STATUS_CLEAN;
+	wl_signal_emit(&output->frame_signal, output);
 }
 
 static int
-- 
1.9.1



More information about the wayland-devel mailing list