[Mesa-dev] [PATCH 069/101] mesa: add KHR_no_error support to glDrawTransformFeedback*()

Samuel Pitoiset samuel.pitoiset at gmail.com
Fri Jul 21 17:40:18 UTC 2017


Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
---
 src/mesa/vbo/vbo_exec_array.c | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/src/mesa/vbo/vbo_exec_array.c b/src/mesa/vbo/vbo_exec_array.c
index 809deb7130..92f04726c7 100644
--- a/src/mesa/vbo/vbo_exec_array.c
+++ b/src/mesa/vbo/vbo_exec_array.c
@@ -1442,9 +1442,16 @@ vbo_draw_transform_feedback(struct gl_context *ctx, GLenum mode,
    struct vbo_context *vbo = vbo_context(ctx);
    struct _mesa_prim prim;
 
-   if (!_mesa_validate_DrawTransformFeedback(ctx, mode, obj, stream,
-                                             numInstances)) {
-      return;
+   if (_mesa_is_no_error_enabled(ctx)) {
+      FLUSH_CURRENT(ctx, 0);
+
+      if (ctx->NewState)
+         _mesa_update_state(ctx);
+   } else {
+      if (!_mesa_validate_DrawTransformFeedback(ctx, mode, obj, stream,
+                                                numInstances)) {
+         return;
+      }
    }
 
    if (ctx->Driver.GetTransformFeedbackVertexCount &&
-- 
2.13.3



More information about the mesa-dev mailing list