mesa: Fold error generation into _mesa_valid_prim_mode().
authorEric Anholt <eric@anholt.net>
Wed, 14 Mar 2012 21:39:15 +0000 (14:39 -0700)
committerEric Anholt <eric@anholt.net>
Tue, 20 Mar 2012 05:01:22 +0000 (22:01 -0700)
commit7ca4f07b5b77ccac0a9b60dc5ac9082906b5947e
tree95685d366aef37c3d16c5f6dccc3b3dd5777a3dd
parentca760181b4420696c7e86aa2951d7203522ad1e8
mesa: Fold error generation into _mesa_valid_prim_mode().

We want to start emitting an INVALID_OPERATION from here for transform
feedback.  Note that this forced dlist.c to almost not use this
function, since it wants different behavior during dlist compile.
Just pull the non-TF, non-GS test out for compile, because:

1) TF doesn't matter in that case because there's no drawing.
2) I don't think we're going to see GSes and display lists in the same
   context, if we don't do GL_ARB_compatibility.

Reviewed-by: Brian Paul <brianp@vmware.com>
src/mesa/main/api_validate.c
src/mesa/main/api_validate.h
src/mesa/main/dlist.c
src/mesa/vbo/vbo_exec_api.c