diff options
author | Derek Foreman <derek.foreman@collabora.com> | 2023-07-31 14:19:49 -0500 |
---|---|---|
committer | Marius Vlad <marius.vlad@collabora.com> | 2023-08-02 12:08:19 +0300 |
commit | ea4700c81f03c3f3b2aeea5dfc5466b57f184ad2 (patch) | |
tree | 6158b57f67943817274cca192042d9ed6d87129d /libweston/compositor.c | |
parent | 1d59530e4b72dbf89ac5f6485a4ca2a3b45e2120 (diff) |
libweston: Fix "fix paint_node_damage_below"
Commit 43b59786 errantly claimed that paint_node_damage_below() needed to
damage all planes because it's used when moving paint nodes between
planes.
This is wrong because the destination plane will receive damage correctly
from paint_node_update_late() when the node's visible region is added to
its damage.
Leave the rest of that commit's changes, but make it once again only
damage the plane the node is currently on.
The problem this caused is easily seen by turning on triangle fan debug
and moving the mouse. Extra damage is generated beneath the cursor plane.
Fixes 43b59786
Signed-off-by: Derek Foreman <derek.foreman@collabora.com>
Diffstat (limited to 'libweston/compositor.c')
-rw-r--r-- | libweston/compositor.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libweston/compositor.c b/libweston/compositor.c index 239dd2b6..5fd74130 100644 --- a/libweston/compositor.c +++ b/libweston/compositor.c @@ -164,6 +164,9 @@ paint_node_damage_below(struct weston_paint_node *pnode) if (lower_node == pnode) break; + if (lower_node->plane != pnode->plane) + continue; + pixman_region32_union(&lower_node->damage, &lower_node->damage, &pnode->visible); } |