summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/shaderapi.c
diff options
context:
space:
mode:
authorSamuel Pitoiset <[email protected]>2017-07-19 14:42:07 +0200
committerSamuel Pitoiset <[email protected]>2017-07-31 13:53:40 +0200
commitffe8813b02590bcd00437fe5cdc1103273ac2920 (patch)
tree90a9b742320e2b5b93fb3ad3b5ff22f230d85349 /src/mesa/main/shaderapi.c
parent6b9087a45dc4c21bb296110770c3e2b8d98cdb49 (diff)
mesa: add KHR_no_error support to glDetachShader() and glDetachObjectARB()
Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
Diffstat (limited to 'src/mesa/main/shaderapi.c')
-rw-r--r--src/mesa/main/shaderapi.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c
index 29e2ed75a5a..e690e4731fa 100644
--- a/src/mesa/main/shaderapi.c
+++ b/src/mesa/main/shaderapi.c
@@ -504,6 +504,13 @@ detach_shader_error(struct gl_context *ctx, GLuint program, GLuint shader)
}
+static void
+detach_shader_no_error(struct gl_context *ctx, GLuint program, GLuint shader)
+{
+ detach_shader(ctx, program, shader, true);
+}
+
+
/**
* Return list of shaders attached to shader program.
*/
@@ -1508,6 +1515,14 @@ _mesa_DeleteShader(GLuint name)
void GLAPIENTRY
+_mesa_DetachObjectARB_no_error(GLhandleARB program, GLhandleARB shader)
+{
+ GET_CURRENT_CONTEXT(ctx);
+ detach_shader_no_error(ctx, program, shader);
+}
+
+
+void GLAPIENTRY
_mesa_DetachObjectARB(GLhandleARB program, GLhandleARB shader)
{
GET_CURRENT_CONTEXT(ctx);
@@ -1516,6 +1531,14 @@ _mesa_DetachObjectARB(GLhandleARB program, GLhandleARB shader)
void GLAPIENTRY
+_mesa_DetachShader_no_error(GLuint program, GLuint shader)
+{
+ GET_CURRENT_CONTEXT(ctx);
+ detach_shader_no_error(ctx, program, shader);
+}
+
+
+void GLAPIENTRY
_mesa_DetachShader(GLuint program, GLuint shader)
{
GET_CURRENT_CONTEXT(ctx);