From: Zack Rusin Date: Tue, 23 Apr 2013 00:44:21 +0000 (-0400) Subject: draw/gs: preserve leading vertex info for gs X-Git-Tag: android-x86-4.4-r1~202 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=1a87473998b4af2dbe37aa3ce0c004e62d3fe2c0;p=android-x86%2Fexternal-mesa.git draw/gs: preserve leading vertex info for gs We need to handle the leading vertex information when assembling primitives for the geometry shader otherwise the resulting triangles will have vertices at incorrect input locations. Signed-off-by: Zack Rusin Reviewed-by: José Fonseca --- diff --git a/src/gallium/auxiliary/draw/draw_gs_tmp.h b/src/gallium/auxiliary/draw/draw_gs_tmp.h index 92b6fb75ea1..b10bbc413d9 100644 --- a/src/gallium/auxiliary/draw/draw_gs_tmp.h +++ b/src/gallium/auxiliary/draw/draw_gs_tmp.h @@ -10,7 +10,7 @@ const unsigned prim_flags = input_prims->flags; \ const unsigned count = input_prims->count; \ const boolean quads_flatshade_last = FALSE; \ - const boolean last_vertex_last = TRUE; \ + const boolean last_vertex_last = !gs->draw->rasterizer->flatshade_first; \ do { \ debug_assert(input_prims->primitive_count == 1); \ switch (prim) { \