From: Brian Paul Date: Fri, 14 Aug 2009 17:31:00 +0000 (-0600) Subject: vbo: call _mesa_valid_to_render() X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e3d47515f9b376b00743137529b4ca35a8436c92;p=mesa.git vbo: call _mesa_valid_to_render() --- diff --git a/src/mesa/vbo/vbo_exec_array.c b/src/mesa/vbo/vbo_exec_array.c index ddf6ca1e070..4148469ef45 100644 --- a/src/mesa/vbo/vbo_exec_array.c +++ b/src/mesa/vbo/vbo_exec_array.c @@ -489,8 +489,7 @@ vbo_exec_DrawArrays(GLenum mode, GLint start, GLsizei count) if (ctx->NewState) _mesa_update_state( ctx ); - if (!vbo_validate_shaders(ctx)) { - _mesa_error(ctx, GL_INVALID_OPERATION, "glDrawArrays(bad shader)"); + if (!_mesa_valid_to_render(ctx, "glDrawArrays")) { return; } @@ -604,8 +603,7 @@ vbo_validated_drawrangeelements(GLcontext *ctx, GLenum mode, if (ctx->NewState) _mesa_update_state( ctx ); - if (!vbo_validate_shaders(ctx)) { - _mesa_error(ctx, GL_INVALID_OPERATION, "glDrawRangeElements(bad shader)"); + if (!_mesa_valid_to_render(ctx, "glDraw[Range]Elements")) { return; }