summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
diff options
context:
space:
mode:
authorMarta Lofstedt <[email protected]>2015-08-19 20:25:22 +0200
committerMarta Lofstedt <[email protected]>2015-09-22 12:21:59 +0200
commit6c3de8996fbe9447e092cc75ccdd6f720fabaf4d (patch)
treef126a5536b1573b28bcec8edebda493c89367e2a /src/mesa/main
parent7f8815bcb9af9b4b374ad7bd6e7cfa7529a6c980 (diff)
mesa/es3.1 : Align OpenGL ES 3.1 glBindVertexBuffer error handling with OpenGL Core
According to OpenGL ES 3.1 specification 10.3.1: "An INVALID_OPERATION error is generated if buffer is not zero or a name returned from a previous call to GenBuffers, or if such a name has since been deleted with DeleteBuffers." This error check was previously limited to OpenGL Core. Signed-off-by: Marta Lofstedt <[email protected]>
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/bufferobj.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c
index 3b87654c5d2..23da83e8b80 100644
--- a/src/mesa/main/bufferobj.c
+++ b/src/mesa/main/bufferobj.c
@@ -916,7 +916,7 @@ _mesa_handle_bind_buffer_gen(struct gl_context *ctx,
{
struct gl_buffer_object *buf = *buf_handle;
- if (!buf && ctx->API == API_OPENGL_CORE) {
+ if (!buf && (ctx->API == API_OPENGL_CORE || _mesa_is_gles31(ctx))) {
_mesa_error(ctx, GL_INVALID_OPERATION, "%s(non-gen name)", caller);
return false;
}