[Mesa-dev] [PATCH] draw: fix a regression in computing max elt
Zack Rusin
zackr at vmware.com
Thu Jun 13 10:37:46 PDT 2013
gl can use elts without setting indices, in which case
our eltMax was set to 0 and always invoking the overflow
condition. So by default set eltMax to maximum, it will
be curbed by draw_set_indexes (if it ever comes) and if
not then it will let gl's glVertexPointer/glDrawArrays
work correctly. Fixes piglit's
triangle-rasterization-overdraw test.
Signed-off-by: Zack Rusin <zackr at vmware.com>
---
src/gallium/auxiliary/draw/draw_context.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/gallium/auxiliary/draw/draw_context.c b/src/gallium/auxiliary/draw/draw_context.c
index 22c0e9b..4a08765 100644
--- a/src/gallium/auxiliary/draw/draw_context.c
+++ b/src/gallium/auxiliary/draw/draw_context.c
@@ -138,6 +138,7 @@ boolean draw_init(struct draw_context *draw)
draw->clip_z = TRUE;
draw->pt.user.planes = (float (*) [DRAW_TOTAL_CLIP_PLANES][4]) &(draw->plane[0]);
+ draw->pt.user.eltMax = ~0;
if (!draw_pipeline_init( draw ))
return FALSE;
--
1.7.10.4
More information about the mesa-dev
mailing list