OSDN Git Service

mesa: use array->BufferObj instead of ctx->Array.ArrayBufferObj
authorBrian Paul <brianp@vmware.com>
Wed, 6 May 2009 19:02:38 +0000 (13:02 -0600)
committerBrian Paul <brianp@vmware.com>
Thu, 7 May 2009 16:12:33 +0000 (10:12 -0600)
No difference, but a little more understandable.

src/mesa/main/varray.c

index 629be60..527555b 100644 (file)
@@ -73,8 +73,8 @@ update_array(GLcontext *ctx, struct gl_client_array *array,
     * Later in glDrawArrays we'll check if start + count > _MaxElement to
     * be sure we won't go out of bounds.
     */
-   if (ctx->Array.ArrayBufferObj->Name)
-      array->_MaxElement = ((GLsizeiptrARB) ctx->Array.ArrayBufferObj->Size
+   if (array->BufferObj->Name)
+      array->_MaxElement = ((GLsizeiptrARB) array->BufferObj->Size
                             - (GLsizeiptrARB) array->Ptr + array->StrideB
                             - elementSize) / array->StrideB;
    else