diff options
author | Brian <brian.paul@tungstengraphics.com> | 2007-11-21 15:40:20 -0700 |
---|---|---|
committer | Brian <brian.paul@tungstengraphics.com> | 2007-11-21 15:40:20 -0700 |
commit | fbe68bf6b286056bb03f44907a078918d04cbdfd (patch) | |
tree | 40535ef7aab0350bce053e3f3b432f2c454461d6 /src/mesa/pipe/draw/draw_flatshade.c | |
parent | 5a6017d496ccce94d7e3cf9a6cfe1db886dcc767 (diff) |
Simplify draw module's vertex_info.
No longer store the vertex header and clip pos info in the draw module's
vertex_info. The vertex_info just describes the data[] elements.
This simplifies the code in several places.
Diffstat (limited to 'src/mesa/pipe/draw/draw_flatshade.c')
-rw-r--r-- | src/mesa/pipe/draw/draw_flatshade.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/pipe/draw/draw_flatshade.c b/src/mesa/pipe/draw/draw_flatshade.c index 3b22c01b34..d46e53f2be 100644 --- a/src/mesa/pipe/draw/draw_flatshade.c +++ b/src/mesa/pipe/draw/draw_flatshade.c @@ -60,8 +60,9 @@ static INLINE void copy_colors( struct draw_stage *stage, uint i; /* Look for constant/flat attribs and duplicate from src to dst vertex */ - for (i = 1; i < num_attribs - 2; i++) { - if (interp[i + 2] == INTERP_CONSTANT) { + /* skip attrib[0] which is vert pos */ + for (i = 1; i < num_attribs; i++) { + if (interp[i] == INTERP_CONSTANT) { copy_attr( i, dst, src ); } } |