mesa: add KHR_no_error support for glBindTextureUnit()
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Mon, 26 Jun 2017 10:31:37 +0000 (12:31 +0200)
committerSamuel Pitoiset <samuel.pitoiset@gmail.com>
Wed, 28 Jun 2017 08:25:12 +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_direct_state_access.xml
src/mesa/main/texobj.c
src/mesa/main/texobj.h

index c9031c1a1acfbc727c8f1d25cb7113fa4a979067..860bbbd28ab19e0771bb99015c7041d36b00feab 100644 (file)
       <param name="texture" type="GLuint" />
    </function>
 
-   <function name="BindTextureUnit">
+   <function name="BindTextureUnit" no_error="true">
       <param name="unit" type="GLuint" />
       <param name="texture" type="GLuint" />
    </function>
index 5337f0513e4678ef488f37efa4144e3dc5b85e00..30d3c961e6ebb09b65d3126561fc2032b00d4868 100644 (file)
@@ -1740,6 +1740,14 @@ bind_texture_unit(struct gl_context *ctx, GLuint unit, GLuint texture,
 }
 
 
+void GLAPIENTRY
+_mesa_BindTextureUnit_no_error(GLuint unit, GLuint texture)
+{
+   GET_CURRENT_CONTEXT(ctx);
+   bind_texture_unit(ctx, unit, texture, true);
+}
+
+
 void GLAPIENTRY
 _mesa_BindTextureUnit(GLuint unit, GLuint texture)
 {
index 1c68bd8ec7d7ba5075c3dddd276f9ec8cd4bc176..a82c97226392e9bb01ce959b322c5e467b5bca3b 100644 (file)
@@ -190,6 +190,9 @@ _mesa_DeleteTextures( GLsizei n, const GLuint *textures );
 extern void GLAPIENTRY
 _mesa_BindTexture( GLenum target, GLuint texture );
 
+void GLAPIENTRY
+_mesa_BindTextureUnit_no_error(GLuint unit, GLuint texture);
+
 extern void GLAPIENTRY
 _mesa_BindTextureUnit(GLuint unit, GLuint texture);