diff options
author | Brian Paul <[email protected]> | 2011-08-30 09:44:47 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2011-08-30 10:17:52 -0600 |
commit | 642bbc6f596722492470c4322a9c011e1705a951 (patch) | |
tree | 9f9395979608d33ca7504433c7a8656bb9eb6d9a | |
parent | 16f442e9d58cc50a40d1f85e90a13a909fc9cab1 (diff) |
tnl: use buffer helper functions to improve readbility
-rw-r--r-- | src/mesa/tnl/t_draw.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mesa/tnl/t_draw.c b/src/mesa/tnl/t_draw.c index 86af4b7cfe2..a5225c439b5 100644 --- a/src/mesa/tnl/t_draw.c +++ b/src/mesa/tnl/t_draw.c @@ -26,6 +26,7 @@ */ #include "main/glheader.h" +#include "main/bufferobj.h" #include "main/condrender.h" #include "main/context.h" #include "main/imports.h" @@ -346,7 +347,8 @@ static void bind_indices( struct gl_context *ctx, return; } - if (ib->obj->Name && !ib->obj->Pointer) { + if (_mesa_is_bufferobj(ib->obj) && !_mesa_bufferobj_mapped(ib->obj)) { + /* if the buffer object isn't mapped yet, map it now */ unsigned map_size; switch (ib->type) { |