mesa: set additional fields in _mesa_buffer_map_range()
authorBrian Paul <brianp@vmware.com>
Mon, 31 Aug 2009 15:12:04 +0000 (09:12 -0600)
committerBrian Paul <brianp@vmware.com>
Mon, 31 Aug 2009 15:12:04 +0000 (09:12 -0600)
src/mesa/main/bufferobj.c

index 165eec019af22d1259d5900f24a74e0bc8baef99..ebca798635d2c12ffa0a217b7b2cf045456f410c 100644 (file)
@@ -445,11 +445,13 @@ _mesa_buffer_map_range( GLcontext *ctx, GLenum target, GLintptr offset,
 {
    (void) ctx;
    (void) target;
-   (void) access;
-   (void) length;
    assert(!_mesa_bufferobj_mapped(bufObj));
    /* Just return a direct pointer to the data */
-   return bufObj->Data + offset;
+   bufObj->Pointer = bufObj->Data + offset;
+   bufObj->Length = length;
+   bufObj->Offset = offset;
+   bufObj->AccessFlags = access;
+   return bufObj->Pointer;
 }