gl-renderer: Draw holes on primary plane for the view on underlay

Signed-off-by: Chao Guo <chao.guo@nxp.com>
This commit is contained in:
Chao Guo 2024-06-17 17:05:32 +09:00 committed by Marius Vlad
parent 99eff1276a
commit 827e22761b
2 changed files with 11 additions and 1 deletions

View file

@ -225,6 +225,15 @@ maybe_replace_paint_node(struct weston_paint_node *pnode)
pnode->solid = placeholder_color;
return;
}
if (pnode->need_hole) {
pnode->draw_solid = true;
pnode->is_fully_opaque = true;
pnode->is_fully_blended = false;
pnode->solid = (struct weston_solid_buffer_values) {
0.0, 0.0, 0.0, 0.0
};
return;
}
if (surface->protection_mode !=
WESTON_SURFACE_PROTECTION_MODE_ENFORCED)
return;

View file

@ -1665,7 +1665,8 @@ repaint_views(struct weston_output *output, pixman_region32_t *damage)
wl_list_for_each_reverse(pnode, &output->paint_node_z_order_list,
z_order_link) {
if (pnode->plane == &output->primary_plane)
if (pnode->plane == &output->primary_plane ||
pnode->need_hole)
draw_paint_node(pnode, damage);
}