diff options
-rw-r--r-- | src/sna/gen6_render.c | 2 | ||||
-rw-r--r-- | src/sna/gen7_render.c | 2 | ||||
-rw-r--r-- | src/sna/sna_trapezoids_boxes.c | 3 | ||||
-rw-r--r-- | src/sna/sna_trapezoids_mono.c | 3 |
4 files changed, 8 insertions, 2 deletions
diff --git a/src/sna/gen6_render.c b/src/sna/gen6_render.c index 8c570007..a2b4082c 100644 --- a/src/sna/gen6_render.c +++ b/src/sna/gen6_render.c @@ -2159,7 +2159,7 @@ gen6_render_composite(struct sna *sna, width, height, tmp); - if (op == PictOpClear) + if (op == PictOpClear && src == sna->clear) op = PictOpSrc; tmp->op = op; if (!gen6_composite_set_target(sna, tmp, dst, diff --git a/src/sna/gen7_render.c b/src/sna/gen7_render.c index 82c785f7..f9408031 100644 --- a/src/sna/gen7_render.c +++ b/src/sna/gen7_render.c @@ -2437,7 +2437,7 @@ gen7_render_composite(struct sna *sna, width, height, tmp); - if (op == PictOpClear) + if (op == PictOpClear && src == sna->clear) op = PictOpSrc; tmp->op = op; if (!gen7_composite_set_target(sna, tmp, dst, diff --git a/src/sna/sna_trapezoids_boxes.c b/src/sna/sna_trapezoids_boxes.c index 4b0346b9..23a3b457 100644 --- a/src/sna/sna_trapezoids_boxes.c +++ b/src/sna/sna_trapezoids_boxes.c @@ -197,6 +197,9 @@ composite_aligned_boxes(struct sna *sna, goto done; } + if (op == PictOpClear && sna->clear) + src = sna->clear; + if (force_fallback || !sna->render.composite(sna, op, src, NULL, dst, src_x, src_y, diff --git a/src/sna/sna_trapezoids_mono.c b/src/sna/sna_trapezoids_mono.c index f7b9a1c7..40d03819 100644 --- a/src/sna/sna_trapezoids_mono.c +++ b/src/sna/sna_trapezoids_mono.c @@ -803,6 +803,9 @@ mono_trapezoids_span_converter(struct sna *sna, unbounded = (!sna_drawable_is_clear(dst->pDrawable) && !operator_is_bounded(op)); + if (op == PictOpClear && mono.sna->clear) + src = mono.sna->clear; + mono.sna = sna; if (!mono.sna->render.composite(mono.sna, op, src, NULL, dst, src_x + mono.clip.extents.x1 - dst_x - dx, |