diff options
author | Paul Berry <stereotype441@gmail.com> | 2013-08-27 20:51:31 -0700 |
---|---|---|
committer | Paul Berry <stereotype441@gmail.com> | 2013-09-09 09:34:46 -0700 |
commit | 2924b5f73bd9468e59da9bf53e88c314669a729f (patch) | |
tree | 3e6cbdda6516a59379fd3c774077e22e433df28c /src | |
parent | 2937d704dcae4451b2baa7d02f97205e73b37c8c (diff) | |
download | external_mesa3d-2924b5f73bd9468e59da9bf53e88c314669a729f.zip external_mesa3d-2924b5f73bd9468e59da9bf53e88c314669a729f.tar.gz external_mesa3d-2924b5f73bd9468e59da9bf53e88c314669a729f.tar.bz2 |
vbo: Implement new gs prim types in vbo_count_tessellated_primitives.
Reviewed-by: Matt Turner <mattst88@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/vbo/vbo_exec.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/mesa/vbo/vbo_exec.c b/src/mesa/vbo/vbo_exec.c index 9c20bde..aa2c7b0 100644 --- a/src/mesa/vbo/vbo_exec.c +++ b/src/mesa/vbo/vbo_exec.c @@ -149,6 +149,18 @@ vbo_count_tessellated_primitives(GLenum mode, GLuint count, case GL_QUADS: num_primitives = (count / 4) * 2; break; + case GL_LINES_ADJACENCY: + num_primitives = count / 4; + break; + case GL_LINE_STRIP_ADJACENCY: + num_primitives = count >= 4 ? count - 3 : 0; + break; + case GL_TRIANGLES_ADJACENCY: + num_primitives = count / 6; + break; + case GL_TRIANGLE_STRIP_ADJACENCY: + num_primitives = count >= 6 ? (count - 4) / 2 : 0; + break; default: assert(!"Unexpected primitive type in count_tessellated_primitives"); num_primitives = 0; |