summaryrefslogtreecommitdiff
path: root/src/sna/sna_trapezoids.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/sna/sna_trapezoids.c')
-rw-r--r--src/sna/sna_trapezoids.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/sna/sna_trapezoids.c b/src/sna/sna_trapezoids.c
index baba8274..2f346ea3 100644
--- a/src/sna/sna_trapezoids.c
+++ b/src/sna/sna_trapezoids.c
@@ -7827,7 +7827,8 @@ trifan_fallback(CARD8 op,
-bounds.x1, -bounds.y1,
1, (pixman_triangle_t *)&tri);
for (i = 3; i < n; i++) {
- *p[1+ (i%2)] = points[i];
+ *p[1] = *p[2];
+ *p[2] = points[i];
pixman_add_triangles(image,
-bounds.x1, -bounds.y1,
1, (pixman_triangle_t *)&tri);
@@ -7865,7 +7866,8 @@ trifan_fallback(CARD8 op,
src, dst, maskFormat,
xSrc, ySrc, 1, &tri);
for (i = 3; i < n; i++) {
- *p[1 + (i%2)] = points[i];
+ *p[1] = *p[2];
+ *p[2] = points[i];
/* Should xSrc,ySrc be updated? */
triangles_fallback(op,
src, dst, maskFormat,