mirror of
https://github.com/swaywm/sway.git
synced 2024-12-28 07:56:31 +01:00
Set output damage during direct scan-out
During direct scan-out, pass the damaged region to the wlroots backend.
This commit is contained in:
parent
777df22377
commit
ab4f460597
1 changed files with 5 additions and 5 deletions
|
@ -571,6 +571,11 @@ static int output_repaint_timer_handler(void *data) {
|
||||||
fullscreen_con = workspace->current.fullscreen;
|
fullscreen_con = workspace->current.fullscreen;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pixman_region32_t frame_damage;
|
||||||
|
get_frame_damage(output, &frame_damage);
|
||||||
|
wlr_output_set_damage(wlr_output, &frame_damage);
|
||||||
|
pixman_region32_fini(&frame_damage);
|
||||||
|
|
||||||
if (fullscreen_con && fullscreen_con->view && !debug.noscanout) {
|
if (fullscreen_con && fullscreen_con->view && !debug.noscanout) {
|
||||||
// Try to scan-out the fullscreen view
|
// Try to scan-out the fullscreen view
|
||||||
static bool last_scanned_out = false;
|
static bool last_scanned_out = false;
|
||||||
|
@ -609,11 +614,6 @@ static int output_repaint_timer_handler(void *data) {
|
||||||
|
|
||||||
pixman_region32_fini(&damage);
|
pixman_region32_fini(&damage);
|
||||||
|
|
||||||
pixman_region32_t frame_damage;
|
|
||||||
get_frame_damage(output, &frame_damage);
|
|
||||||
wlr_output_set_damage(wlr_output, &frame_damage);
|
|
||||||
pixman_region32_fini(&frame_damage);
|
|
||||||
|
|
||||||
if (!wlr_output_commit(wlr_output)) {
|
if (!wlr_output_commit(wlr_output)) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue