mesa: add KHR_no_error support for glShaderStorageBlockBinding()
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Mon, 26 Jun 2017 13:35:10 +0000 (15:35 +0200)
committerSamuel Pitoiset <samuel.pitoiset@gmail.com>
Wed, 28 Jun 2017 08:25:13 +0000 (10:25 +0200)
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
src/mapi/glapi/gen/ARB_shader_storage_buffer_object.xml
src/mesa/main/uniforms.c
src/mesa/main/uniforms.h

index 6901bdf6d0ef01306759b96a4db6f4fb162b2af4..4d2288227930aa428f41cf56b6fca01bd04a732f 100644 (file)
@@ -25,7 +25,7 @@
 <!-- Duplicated with GL3x.xml: BindBufferRange, BindBufferBase,
      GetIntegeri_v -->
 
-<function name="ShaderStorageBlockBinding">
+<function name="ShaderStorageBlockBinding" no_error="true">
     <param name="program" type="GLuint" />
     <param name="shaderStorageBlockIndex" type="GLuint" />
     <param name="shaderStorageBlockBinding" type="GLuint" />
index 28f530c4f68e94fd1f3bd227fc5bc57f4b666450..194f64a3b2c85dce159ad41c520bc5b1c5d3fff0 100644 (file)
@@ -1162,6 +1162,18 @@ shader_storage_block_binding(struct gl_context *ctx,
    }
 }
 
+void GLAPIENTRY
+_mesa_ShaderStorageBlockBinding_no_error(GLuint program,
+                                         GLuint shaderStorageBlockIndex,
+                                         GLuint shaderStorageBlockBinding)
+{
+   GET_CURRENT_CONTEXT(ctx);
+
+   struct gl_shader_program *shProg = _mesa_lookup_shader_program(ctx, program);
+   shader_storage_block_binding(ctx, shProg, shaderStorageBlockIndex,
+                                shaderStorageBlockBinding);
+}
+
 void GLAPIENTRY
 _mesa_ShaderStorageBlockBinding(GLuint program,
                                GLuint shaderStorageBlockIndex,
index 098b5d40c0d2817773952fcfef9681a52aff830a..1cee90d2a776bfe13abacdd8a2f50af750fcbcd4 100644 (file)
@@ -241,6 +241,12 @@ void GLAPIENTRY
 _mesa_UniformBlockBinding(GLuint program,
                          GLuint uniformBlockIndex,
                          GLuint uniformBlockBinding);
+
+void GLAPIENTRY
+_mesa_ShaderStorageBlockBinding_no_error(GLuint program,
+                                         GLuint shaderStorageBlockIndex,
+                                         GLuint shaderStorageBlockBinding);
+
 void GLAPIENTRY
 _mesa_ShaderStorageBlockBinding(GLuint program,
                                 GLuint shaderStorageBlockIndex,