summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2011-11-06 09:55:09 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2011-11-06 09:56:52 +0000
commit0b9408d972050cb02c1024926c406cd45508a158 (patch)
tree6fa83fccd09530b86d97f10c84bf712e9f5a4ee5
parentc76714c29d29687f941a9112e80223c817185d53 (diff)
sna: Self-intersection of wide PolyLine are only drawn once
We need to process the union of the PolyLine command if lineWidth!=0 so we cannot generally feed lineWidth==1 into our special case handler. Proving the lines do not intersect is as difficult as finding the intersections and thereby finding the union of the path - so there is no advantage in adding a check whether a wide line could be special cased. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r--src/sna/sna_accel.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 3c8322ff..e33d45a4 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -4037,7 +4037,7 @@ sna_poly_line(DrawablePtr drawable, GCPtr gc,
flags & 2));
if (gc->fillStyle == FillSolid &&
gc->lineStyle == LineSolid &&
- gc->lineWidth <= 1 &&
+ (gc->lineWidth == 0 || (gc->lineWidth == 1 && n == 1)) &&
PM_IS_SOLID(drawable, gc->planemask)) {
struct sna_pixmap *priv = sna_pixmap_from_drawable(drawable);
struct sna_damage **damage;