diff options
author | Brian <[email protected]> | 2007-08-11 21:21:12 +0100 |
---|---|---|
committer | Brian <[email protected]> | 2007-08-11 21:21:12 +0100 |
commit | 0095be534d633848bc12d73ed9dcc1b9aa41f00a (patch) | |
tree | 82c15888aceec77a526f2828db87f91253f4a886 /src/mesa/drivers/x11/xm_buffer.c | |
parent | 5d42fdb9b70a53938cd29d7ebeaa4b9cedd2e8e3 (diff) |
Change/fix surface allocation functions.
Use xmesa_new_color_surface() for front/back renderbuffer surfaces.
Use xmesa_surface_alloc() for everything else (textures, other renderbuffers)
Diffstat (limited to 'src/mesa/drivers/x11/xm_buffer.c')
-rw-r--r-- | src/mesa/drivers/x11/xm_buffer.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/mesa/drivers/x11/xm_buffer.c b/src/mesa/drivers/x11/xm_buffer.c index 4cd2ab7c6bd..52629aca182 100644 --- a/src/mesa/drivers/x11/xm_buffer.c +++ b/src/mesa/drivers/x11/xm_buffer.c @@ -252,10 +252,6 @@ static void finish_surface_init(GLcontext *ctx, struct xmesa_renderbuffer *xrb) { struct pipe_context *pipe = ctx->st->pipe; - - if (!xrb->St.surface) { - xrb->St.surface = xmesa_new_surface(ctx, xrb); - } if (!xrb->St.surface->region) { xrb->St.surface->region = pipe->region_alloc(pipe, 1, 0, 0, 0x0); } @@ -391,10 +387,9 @@ xmesa_create_renderbuffer(GLcontext *ctx, GLuint name, const GLvisual *visual, } /* only need to set Red/Green/EtcBits fields for user-created RBs */ - xrb->St.surface = xmesa_surface_alloc(pipe, pipeFormat); + xrb->St.surface = xmesa_new_color_surface(pipe, pipeFormat); xms = (struct xmesa_surface *) xrb->St.surface; xms->xrb = xrb; - } return xrb; } |