diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2014-03-14 13:08:43 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2014-03-14 13:40:55 +0000 |
commit | c64d2572bafeacae25e9b58c8372ce91858c3832 (patch) | |
tree | 0c79534b73c4da3bc44f67182bce058fd9b87456 /src/sna/sna_composite.c | |
parent | b61e6398f0cf94d3c483e30c05ceae4a8383d16c (diff) |
sna: Allow some leeway when deciding to discard common translations
Under PictFilterNearest, we can ignore fractional translations (not all
renderers discard those.) And if we are being approximate, we can loosen
our tolerance as well.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna_composite.c')
-rw-r--r-- | src/sna/sna_composite.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/sna/sna_composite.c b/src/sna/sna_composite.c index 74dfc9ed..d34b5172 100644 --- a/src/sna/sna_composite.c +++ b/src/sna/sna_composite.c @@ -527,7 +527,9 @@ sna_composite_fb(CARD8 op, src->filter != PictFilterConvolution && (op == PictOpSrc || (op == PictOpOver && !PICT_FORMAT_A(src->format))) && (dst->format == src->format || dst->format == alphaless(src->format)) && - sna_transform_is_integer_translation(src->transform, &tx, &ty)) { + sna_transform_is_imprecise_integer_translation(src->transform, src->filter, + dst->polyMode == PolyModePrecise, + &tx, &ty)) { PixmapPtr dst_pixmap = get_drawable_pixmap(dst->pDrawable); PixmapPtr src_pixmap = get_drawable_pixmap(src->pDrawable); int16_t sx = src_x + tx - (dst->pDrawable->x + dst_x); |