mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 11:48:06 +02:00
mesa: inline bind_vertex_array() helper
The previous commit removed the only other user of this function. Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
This commit is contained in:
parent
7927d0378f
commit
f38845b9cb
1 changed files with 6 additions and 17 deletions
|
|
@ -417,19 +417,19 @@ _mesa_all_buffers_are_unmapped(const struct gl_vertex_array_object *vao)
|
|||
|
||||
|
||||
/**
|
||||
* Helper for _mesa_BindVertexArray().
|
||||
* \param genRequired specifies behavour when id was not generated with
|
||||
* glGenVertexArrays().
|
||||
* ARB version of glBindVertexArray()
|
||||
*/
|
||||
static void
|
||||
bind_vertex_array(struct gl_context *ctx, GLuint id)
|
||||
void GLAPIENTRY
|
||||
_mesa_BindVertexArray( GLuint id )
|
||||
{
|
||||
GET_CURRENT_CONTEXT(ctx);
|
||||
|
||||
struct gl_vertex_array_object * const oldObj = ctx->Array.VAO;
|
||||
struct gl_vertex_array_object *newObj = NULL;
|
||||
|
||||
assert(oldObj != NULL);
|
||||
|
||||
if ( oldObj->Name == id )
|
||||
if (oldObj->Name == id)
|
||||
return; /* rebinding the same array object- no change */
|
||||
|
||||
/*
|
||||
|
|
@ -482,17 +482,6 @@ bind_vertex_array(struct gl_context *ctx, GLuint id)
|
|||
}
|
||||
|
||||
|
||||
/**
|
||||
* ARB version of glBindVertexArray()
|
||||
*/
|
||||
void GLAPIENTRY
|
||||
_mesa_BindVertexArray( GLuint id )
|
||||
{
|
||||
GET_CURRENT_CONTEXT(ctx);
|
||||
bind_vertex_array(ctx, id);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Delete a set of array objects.
|
||||
*
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue