OSDN Git Service

Merge commit 'origin/master' into gallium-map-range
[android-x86/external-mesa.git] / src / mesa / state_tracker / st_cb_bufferobjects.c
index 2765ec2..45fbe8c 100644 (file)
@@ -74,11 +74,10 @@ st_bufferobj_alloc(GLcontext *ctx, GLuint name, GLenum target)
 static void
 st_bufferobj_free(GLcontext *ctx, struct gl_buffer_object *obj)
 {
-   struct pipe_context *pipe = st_context(ctx)->pipe;
    struct st_buffer_object *st_obj = st_buffer_object(obj);
 
    if (st_obj->buffer) 
-      pipe_buffer_reference(pipe->screen, &st_obj->buffer, NULL);
+      pipe_buffer_reference(&st_obj->buffer, NULL);
 
    _mesa_free(st_obj);
 }
@@ -165,7 +164,7 @@ st_bufferobj_data(GLcontext *ctx,
       buffer_usage = 0;
    }
 
-   pipe_buffer_reference( pipe->screen, &st_obj->buffer, NULL );
+   pipe_buffer_reference( &st_obj->buffer, NULL );
 
    st_obj->buffer = pipe_buffer_create( pipe->screen, 32, buffer_usage, size );