diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2011-11-14 12:04:49 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2011-11-14 12:13:58 +0000 |
commit | 99338ebe61917a07611cbc81cfaf70c0ec905014 (patch) | |
tree | b015493a2affc8842050f81ead913ef17b2ff159 /src/sna/sna_damage.c | |
parent | 00d1c539e4b69636bfc35c0c47a6f1db3a33e731 (diff) |
sna: Check whether damage can be reduced to all-damage on moving to GPU
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna_damage.c')
-rw-r--r-- | src/sna/sna_damage.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/sna/sna_damage.c b/src/sna/sna_damage.c index 2d7d65d7..95a92a53 100644 --- a/src/sna/sna_damage.c +++ b/src/sna/sna_damage.c @@ -1242,10 +1242,9 @@ static int _sna_damage_get_boxes(struct sna_damage *damage, BoxPtr *boxes) return REGION_NUM_RECTS(&damage->region); } -struct sna_damage *_sna_damage_reduce(struct sna_damage *damage, - int width, int height) +struct sna_damage *_sna_damage_reduce(struct sna_damage *damage) { - DBG(("%s(width=%d, height=%d)\n", __FUNCTION__, width, height)); + DBG(("%s\n", __FUNCTION__)); if (damage->n) __sna_damage_reduce(damage); @@ -1253,13 +1252,6 @@ struct sna_damage *_sna_damage_reduce(struct sna_damage *damage, if (!pixman_region_not_empty(&damage->region)) { __sna_damage_destroy(damage); damage = NULL; - } else { - if (damage->region.data == NULL && - damage->extents.x1 <= 0 && - damage->extents.y1 <= 0 && - damage->extents.x2 >= width && - damage->extents.y2 >= height) - damage = _sna_damage_all(damage, width, height); } return damage; |