mesa: create bind_buffer_range() helper

This will help us add KHR_no_error support.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Tested-by: Dieter Nützel <Dieter@nuetzel-hh.de>
This commit is contained in:
Timothy Arceri
2017-05-22 15:47:01 +10:00
parent 3eb6d34dfc
commit b8174a837f
+10 -3
View File
@@ -3991,9 +3991,9 @@ bind_atomic_buffers(struct gl_context *ctx,
_mesa_HashUnlockMutex(ctx->Shared->BufferObjects);
}
void GLAPIENTRY
_mesa_BindBufferRange(GLenum target, GLuint index,
GLuint buffer, GLintptr offset, GLsizeiptr size)
static ALWAYS_INLINE void
bind_buffer_range(GLenum target, GLuint index, GLuint buffer, GLintptr offset,
GLsizeiptr size)
{
GET_CURRENT_CONTEXT(ctx);
struct gl_buffer_object *bufObj;
@@ -4055,6 +4055,13 @@ _mesa_BindBufferRange(GLenum target, GLuint index,
}
}
void GLAPIENTRY
_mesa_BindBufferRange(GLenum target, GLuint index,
GLuint buffer, GLintptr offset, GLsizeiptr size)
{
bind_buffer_range(target, index, buffer, offset, size);
}
void GLAPIENTRY
_mesa_BindBufferBase(GLenum target, GLuint index, GLuint buffer)
{