mirror of
https://gitlab.freedesktop.org/wayland/weston.git
synced 2026-05-07 06:08:05 +02:00
xwm: Fix silly region math
We were setting up the opaque region to be the window size and then intersecting with the opaque rectange that's always contained in the window rectangle. Just initialize to the opaque rectangle.
This commit is contained in:
parent
d8b617deea
commit
25bb696fc8
1 changed files with 4 additions and 8 deletions
|
|
@ -816,17 +816,13 @@ weston_wm_window_draw_decoration(void *data)
|
|||
|
||||
if (window->surface) {
|
||||
pixman_region32_fini(&window->surface->pending.opaque);
|
||||
pixman_region32_init_rect(&window->surface->pending.opaque, 0, 0,
|
||||
width, height);
|
||||
|
||||
/* We leave an extra pixel around the X window area to
|
||||
* make sure we don't sample from the undefined alpha
|
||||
* channel when filtering. */
|
||||
pixman_region32_intersect_rect(&window->surface->pending.opaque,
|
||||
&window->surface->pending.opaque,
|
||||
x - 1, y - 1,
|
||||
window->width + 2,
|
||||
window->height + 2);
|
||||
pixman_region32_init_rect(&window->surface->pending.opaque,
|
||||
x - 1, y - 1,
|
||||
window->width + 2,
|
||||
window->height + 2);
|
||||
window->surface->geometry.dirty = 1;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue