mirror of
https://github.com/brl/mutter.git
synced 2024-11-21 15:40:41 -05:00
window-actor/x11: Disable culling on window actor level
This shape region culling was wrongly implemented inf5a28aa9
, as it does not take frame offsets into account, and is also redundant, as we already set the opaque region of the underlying surface accordingly. The other parts were implemented inac7aa114
, the reason given in the commit message: ``` Wayland clients do this through the opaque region in the surface actor. However X11 clients were considered fully transparent for culling purposes, which may result in mutter painting other bits of the background or other windows that will be painted over in reality. ``` is wrong though - culling on X11 actors works just fine and did only not work in Wayland sessions because of a bug that got fixed in19814497
. In conclusion the whole part appears to be redundand and some testing done suggests the same. Drop it. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1082
This commit is contained in:
parent
372d73e275
commit
6831f2edb4
@ -1451,45 +1451,6 @@ meta_window_actor_x11_cull_out (MetaCullable *cullable,
|
||||
|
||||
cullable_parent_iface->cull_out (cullable, unobscured_region, clip_region);
|
||||
|
||||
if ((unobscured_region || clip_region) &&
|
||||
meta_window_actor_is_opaque (META_WINDOW_ACTOR (self)))
|
||||
{
|
||||
MetaWindow *window =
|
||||
meta_window_actor_get_meta_window (META_WINDOW_ACTOR (self));
|
||||
|
||||
if (window->shape_region)
|
||||
{
|
||||
if (unobscured_region)
|
||||
cairo_region_subtract (unobscured_region, window->shape_region);
|
||||
if (clip_region)
|
||||
cairo_region_subtract (clip_region, window->shape_region);
|
||||
}
|
||||
else
|
||||
{
|
||||
cairo_region_t *region = meta_window_get_frame_bounds (window);
|
||||
|
||||
if (region)
|
||||
{
|
||||
if (unobscured_region)
|
||||
cairo_region_subtract (unobscured_region, region);
|
||||
if (clip_region)
|
||||
cairo_region_subtract (clip_region, region);
|
||||
}
|
||||
else
|
||||
{
|
||||
cairo_rectangle_int_t rect;
|
||||
|
||||
meta_window_get_frame_rect (window, &rect);
|
||||
rect.x = rect.y = 0;
|
||||
|
||||
if (unobscured_region)
|
||||
cairo_region_subtract_rectangle (unobscured_region, &rect);
|
||||
if (clip_region)
|
||||
cairo_region_subtract_rectangle (clip_region, &rect);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
set_clip_region_beneath (self, clip_region);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user