From 61667404ce9093e669df7fd1efa9b68698ca5639 Mon Sep 17 00:00:00 2001 From: Alexander Orzechowski Date: Tue, 13 Jun 2023 20:51:20 -0400 Subject: [PATCH] wlr_scene: Clear damage ring on scale change If we were trying to change the scale in wlr_scene_output_build_state, we would be using incorrect damage --- types/scene/wlr_scene.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/types/scene/wlr_scene.c b/types/scene/wlr_scene.c index f3a0db34..32efa4b6 100644 --- a/types/scene/wlr_scene.c +++ b/types/scene/wlr_scene.c @@ -1590,6 +1590,10 @@ bool wlr_scene_output_build_state(struct wlr_scene_output *scene_output, } if (state->committed & WLR_OUTPUT_STATE_SCALE) { + if (render_data.scale != state->scale) { + wlr_damage_ring_add_whole(&scene_output->damage_ring); + } + render_data.scale = state->scale; }