mirror of
https://github.com/X11Libre/xserver.git
synced 2026-04-07 17:12:09 +00:00
Fix RegionContainsRect test for PutImage
The return value of RegionContainsRect() is not a boolean but an enum indicating that the region contains the rectangle completely, partially or not at all. We can only take the PutImage fastpath when the region contatins the rectangle completely. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=65964 Signed-off-by: Michel Dänzer <michel.daenzer@amd.com> Reviewed-by: Zhigang Gong <zhigang.gong@linux.intel.com>
This commit is contained in:
committed by
Eric Anholt
parent
2ea618f2cf
commit
61fca4342a
@@ -287,7 +287,7 @@ _glamor_put_image(DrawablePtr drawable, GCPtr gc, int depth, int x, int y,
|
||||
box.x2 = x + w + drawable->x;
|
||||
box.y2 = y + h + drawable->y;
|
||||
|
||||
if ((clip != NULL && !RegionContainsRect(clip, &box))
|
||||
if ((clip != NULL && RegionContainsRect(clip, &box) != rgnIN)
|
||||
|| gc->alu != GXcopy) {
|
||||
temp_pixmap = glamor_create_pixmap(drawable->pScreen, w, h, depth, 0);
|
||||
if (temp_pixmap == NULL)
|
||||
|
||||
Reference in New Issue
Block a user