From 48400e0bd6f29eb590dc726ba482856d16f1b3e5 Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Mon, 26 Jun 2017 17:38:22 +0200 Subject: [PATCH] mesa: add KHR_no_error support for glBindAttribLocation() Signed-off-by: Samuel Pitoiset Reviewed-by: Timothy Arceri --- src/mapi/glapi/gen/gl_API.xml | 2 +- src/mesa/main/shader_query.cpp | 11 +++++++++++ src/mesa/main/shaderapi.h | 3 +++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/src/mapi/glapi/gen/gl_API.xml b/src/mapi/glapi/gen/gl_API.xml index d281095..64078c4 100644 --- a/src/mapi/glapi/gen/gl_API.xml +++ b/src/mapi/glapi/gen/gl_API.xml @@ -5301,7 +5301,7 @@ - + diff --git a/src/mesa/main/shader_query.cpp b/src/mesa/main/shader_query.cpp index 9086a90..0f66f75 100644 --- a/src/mesa/main/shader_query.cpp +++ b/src/mesa/main/shader_query.cpp @@ -97,6 +97,17 @@ bind_attrib_location(struct gl_context *ctx, } void GLAPIENTRY +_mesa_BindAttribLocation_no_error(GLuint program, GLuint index, + const GLchar *name) +{ + GET_CURRENT_CONTEXT(ctx); + + struct gl_shader_program *const shProg = + _mesa_lookup_shader_program(ctx, program); + bind_attrib_location(ctx, shProg, index, name, true); +} + +void GLAPIENTRY _mesa_BindAttribLocation(GLuint program, GLuint index, const GLchar *name) { diff --git a/src/mesa/main/shaderapi.h b/src/mesa/main/shaderapi.h index ccc38d9..b2229f7 100644 --- a/src/mesa/main/shaderapi.h +++ b/src/mesa/main/shaderapi.h @@ -143,6 +143,9 @@ extern void GLAPIENTRY _mesa_ValidateProgram(GLuint); +void GLAPIENTRY +_mesa_BindAttribLocation_no_error(GLuint program, GLuint, const GLchar *); + extern void GLAPIENTRY _mesa_BindAttribLocation(GLuint program, GLuint, const GLchar *); -- 2.7.4