move frame_signal emission to weston_output_repaint()
authorLeandro Ribeiro <leandrohr@riseup.net>
Mon, 25 Nov 2019 15:31:46 +0000 (12:31 -0300)
committerLeandro Ribeiro <leandrohr@riseup.net>
Wed, 27 Nov 2019 16:18:42 +0000 (13:18 -0300)
In order to remove duplication and make the code easier to follow, move
frame_signal emission from renderers to weston_output_repaint(). This should
have no observable effect.

Signed-off-by: Leandro Ribeiro <leandrohr@riseup.net>
libweston/compositor.c
libweston/pixman-renderer.c
libweston/renderer-gl/gl-renderer.c

index 72a2905e6da912dae334c84f7595218986d0bd8c..47f7edfdf4d088356d44d1df3aedd8104687d1fa 100644 (file)
@@ -2723,6 +2723,7 @@ weston_output_repaint(struct weston_output *output, void *repaint_data)
                weston_output_update_matrix(output);
 
        r = output->repaint(output, &output_damage, repaint_data);
+       wl_signal_emit(&output->frame_signal, output);
 
        pixman_region32_fini(&output_damage);
 
index 378845d06ce68020cdfd941a2cec69f2d06e5646..f73be2d269ef49f66864bf55725be0e907898a94 100644 (file)
@@ -580,7 +580,6 @@ pixman_renderer_repaint_output(struct weston_output *output,
        pixman_region32_fini(&hw_damage);
 
        pixman_region32_copy(&output->previous_damage, output_damage);
-       wl_signal_emit(&output->frame_signal, output);
 
        /* Actual flip should be done by caller */
 }
index 14c5f8b141877882a06acb1524f9591db49b970b..d10890469a0d127b4199518df8a7a68dadda8eea 100644 (file)
@@ -1474,7 +1474,6 @@ gl_renderer_repaint_output(struct weston_output *output,
        draw_output_borders(output, border_status);
 
        pixman_region32_copy(&output->previous_damage, output_damage);
-       wl_signal_emit(&output->frame_signal, output);
 
        go->end_render_sync = create_render_sync(gr);