sna: Don't call RegionIntersect for the trivial PutImage
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
1bd6665093
commit
87e6dcb3b0
|
|
@ -2525,9 +2525,15 @@ sna_put_image(DrawablePtr drawable, GCPtr gc, int depth,
|
|||
region.extents.y2 = region.extents.y1 + h;
|
||||
region.data = NULL;
|
||||
|
||||
RegionIntersect(®ion, ®ion, gc->pCompositeClip);
|
||||
if (!RegionNotEmpty(®ion))
|
||||
return;
|
||||
if (!region_is_singular(gc->pCompositeClip) ||
|
||||
gc->pCompositeClip->extents.x1 > region.extents.x1 ||
|
||||
gc->pCompositeClip->extents.y1 > region.extents.y1 ||
|
||||
gc->pCompositeClip->extents.x2 < region.extents.x2 ||
|
||||
gc->pCompositeClip->extents.y2 < region.extents.y2) {
|
||||
RegionIntersect(®ion, ®ion, gc->pCompositeClip);
|
||||
if (!RegionNotEmpty(®ion))
|
||||
return;
|
||||
}
|
||||
|
||||
RegionTranslate(®ion, dx, dy);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue