summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLuca Barbieri <[email protected]>2010-08-23 21:43:11 +0200
committerLuca Barbieri <[email protected]>2010-08-23 21:47:47 +0200
commitc0eb479e0782c063a1a781f81b99a18ef649e9ef (patch)
tree5079690ced6d76ac2a221e6bbe4c2b89c4199160 /src
parentbcf7f66a934ebd9c91da90d6e1f9b169c33c746c (diff)
auxiliary: fix nvfx/nv50 primitive splitting for line loops
s->close_first was on the wrong side of the inequality. Caught by blender. Thanks to AndrewR for reporting this.
Diffstat (limited to 'src')
-rw-r--r--src/gallium/auxiliary/util/u_split_prim.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/util/u_split_prim.h b/src/gallium/auxiliary/util/u_split_prim.h
index 206e1ec3118..e63a7c1fadd 100644
--- a/src/gallium/auxiliary/util/u_split_prim.h
+++ b/src/gallium/auxiliary/util/u_split_prim.h
@@ -48,7 +48,7 @@ util_split_prim_next(struct util_split_prim *s, unsigned max_verts)
}
}
- if (s->p_start + s->close_first + max_verts >= s->p_end) {
+ if ((s->p_end - s->p_start) + s->close_first <= max_verts) {
s->emit(s->priv, s->p_start, s->p_end - s->p_start);
if (s->close_first)
s->emit(s->priv, s->start, 1);