diff options
author | Keith Whitwell <keith@tungstengraphics.com> | 2007-12-14 20:14:58 +0000 |
---|---|---|
committer | Keith Whitwell <keith@tungstengraphics.com> | 2007-12-17 10:30:38 +0000 |
commit | 3be91c5a493a219dacf12b4cc279e37f26420cbd (patch) | |
tree | 2ab4ffe81529b2e293895d0e2f7ef72efda52c61 /src/mesa/pipe/i965simple | |
parent | 95adfb9fec808fff1e72c3feb407be13a96397f9 (diff) |
965: fix for non-indexed draw path
Diffstat (limited to 'src/mesa/pipe/i965simple')
-rw-r--r-- | src/mesa/pipe/i965simple/brw_draw.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mesa/pipe/i965simple/brw_draw.c b/src/mesa/pipe/i965simple/brw_draw.c index 01c8ddb227..498bf6b7ee 100644 --- a/src/mesa/pipe/i965simple/brw_draw.c +++ b/src/mesa/pipe/i965simple/brw_draw.c @@ -158,7 +158,8 @@ static boolean brw_try_draw_elements( struct pipe_context *pipe, /* Upload index, vertex data: */ - if (!brw_upload_indices( brw, index_buffer, index_size, start, count )) + if (index_buffer && + !brw_upload_indices( brw, index_buffer, index_size, start, count )) return FALSE; if (!brw_upload_vertex_elements( brw )) @@ -169,7 +170,9 @@ static boolean brw_try_draw_elements( struct pipe_context *pipe, if (brw->state.dirty.brw) brw_validate_state( brw ); - if (brw_emit_prim(brw, TRUE, start, count)) + if (brw_emit_prim(brw, + index_buffer != NULL, + start, count)) return FALSE; return TRUE; |