summaryrefslogtreecommitdiff
path: root/src/mesa/pipe/xlib/xm_buffer.c
diff options
context:
space:
mode:
authorMichel Dänzer <michel@tungstengraphics.com>2007-12-07 12:30:35 +0100
committerMichel Dänzer <michel@tungstengraphics.com>2007-12-07 12:30:35 +0100
commitb859cdf6f191b4d8b56537c8dc30082a7e2d94b3 (patch)
tree4bd3149cc81a2fb6434282a70b34361f94710cfd /src/mesa/pipe/xlib/xm_buffer.c
parent987d59bb83e9e08192563e5f1b52949c5511053c (diff)
Eliminate struct pipe_region.
Directly use struct pipe_buffer_handle for storage and struct pipe_surface for (un)mapping.
Diffstat (limited to 'src/mesa/pipe/xlib/xm_buffer.c')
-rw-r--r--src/mesa/pipe/xlib/xm_buffer.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/mesa/pipe/xlib/xm_buffer.c b/src/mesa/pipe/xlib/xm_buffer.c
index 449e90184b..6fc2f4ba63 100644
--- a/src/mesa/pipe/xlib/xm_buffer.c
+++ b/src/mesa/pipe/xlib/xm_buffer.c
@@ -269,9 +269,8 @@ static void
finish_surface_init(GLcontext *ctx, struct xmesa_renderbuffer *xrb)
{
struct pipe_context *pipe = ctx->st->pipe;
- if (!xrb->St.surface->region) {
- xrb->St.surface->region = pipe->winsys->region_alloc(pipe->winsys, 1,
- 0x0);
+ if (!xrb->St.surface->buffer) {
+ xrb->St.surface->buffer = pipe->winsys->buffer_create(pipe->winsys, 0x0);
}
}
@@ -301,7 +300,7 @@ xmesa_alloc_front_storage(GLcontext *ctx, struct gl_renderbuffer *rb,
rb->Height = height;
rb->InternalFormat = internalFormat;
- if (!xrb->St.surface || !xrb->St.surface->region)
+ if (!xrb->St.surface || !xrb->St.surface->buffer)
finish_surface_init(ctx, xrb);
/* surface info */
@@ -363,7 +362,7 @@ xmesa_alloc_back_storage(GLcontext *ctx, struct gl_renderbuffer *rb,
xrb->origin4 = NULL;
}
- if (!xrb->St.surface || !xrb->St.surface->region)
+ if (!xrb->St.surface || !xrb->St.surface->buffer)
finish_surface_init(ctx, xrb);
xrb->St.surface->width = width;