aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/tnl/t_draw.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2020-03-21 23:56:07 -0400
committerMarek Olšák <[email protected]>2020-04-06 10:28:53 -0400
commit10beee8a7757e956ab0e02ec8402ec1273d8edce (patch)
treec6bce7c442f7f87ed18e973b623ccd9d49cd209a /src/mesa/tnl/t_draw.c
parent58fab9a6fe258395d934b69c454f1b54bcefedf1 (diff)
mesa: remove no longer needed _mesa_is_bufferobj function
All buffers have Name != 0. Note that there is no longer the pointer dereference to get Name, so it's faster. Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4466>
Diffstat (limited to 'src/mesa/tnl/t_draw.c')
-rw-r--r--src/mesa/tnl/t_draw.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/tnl/t_draw.c b/src/mesa/tnl/t_draw.c
index 33d39a7bd20..335161ef0d0 100644
--- a/src/mesa/tnl/t_draw.c
+++ b/src/mesa/tnl/t_draw.c
@@ -291,7 +291,7 @@ static void bind_inputs( struct gl_context *ctx,
const struct gl_array_attributes *attrib = array->VertexAttrib;
const void *ptr;
- if (_mesa_is_bufferobj(binding->BufferObj)) {
+ if (binding->BufferObj) {
if (!binding->BufferObj->Mappings[MAP_INTERNAL].Pointer) {
bo[*nr_bo] = binding->BufferObj;
(*nr_bo)++;
@@ -362,7 +362,7 @@ static void bind_indices( struct gl_context *ctx,
return;
}
- if (_mesa_is_bufferobj(ib->obj) &&
+ if (ib->obj &&
!_mesa_bufferobj_mapped(ib->obj, MAP_INTERNAL)) {
/* if the buffer object isn't mapped yet, map it now */
bo[*nr_bo] = ib->obj;