mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-03-28 07:58:00 -04:00
render: call wl_display_flush() right after wl_surface_commit()
This groups the two calls, for readability.
This commit is contained in:
parent
9ba702ce00
commit
bd8c81547f
1 changed files with 1 additions and 2 deletions
3
render.c
3
render.c
|
|
@ -819,7 +819,6 @@ grid_render(struct terminal *term)
|
||||||
|
|
||||||
wl_surface_set_buffer_scale(term->window->surface, term->scale);
|
wl_surface_set_buffer_scale(term->window->surface, term->scale);
|
||||||
|
|
||||||
|
|
||||||
if (term->wl->presentation != NULL && term->render.presentation_timings) {
|
if (term->wl->presentation != NULL && term->render.presentation_timings) {
|
||||||
clock_gettime(term->wl->presentation_clock_id, &term->render.commit_time);
|
clock_gettime(term->wl->presentation_clock_id, &term->render.commit_time);
|
||||||
|
|
||||||
|
|
@ -835,6 +834,7 @@ grid_render(struct terminal *term)
|
||||||
}
|
}
|
||||||
|
|
||||||
wl_surface_commit(term->window->surface);
|
wl_surface_commit(term->window->surface);
|
||||||
|
wl_display_flush(term->wl->display);
|
||||||
|
|
||||||
#if TIME_FRAME_RENDERING
|
#if TIME_FRAME_RENDERING
|
||||||
struct timeval end_time;
|
struct timeval end_time;
|
||||||
|
|
@ -845,7 +845,6 @@ grid_render(struct terminal *term)
|
||||||
LOG_INFO("frame rendered in %lds %ldus",
|
LOG_INFO("frame rendered in %lds %ldus",
|
||||||
render_time.tv_sec, render_time.tv_usec);
|
render_time.tv_sec, render_time.tv_usec);
|
||||||
#endif
|
#endif
|
||||||
wl_display_flush(term->wl->display);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue