diff options
author | Brian <[email protected]> | 2007-08-01 15:39:19 -0600 |
---|---|---|
committer | Brian <[email protected]> | 2007-08-01 15:39:19 -0600 |
commit | 1ecc648398a51f734ef1e3b729595f41cedf29f9 (patch) | |
tree | 55748347441d6652d5a7b3540b561c35a564c1c1 /src/mesa/drivers/x11 | |
parent | 54135597b8a23a7349f5fa3193642758c229777e (diff) |
rearrange things in xmesa_clear() a bit
Diffstat (limited to 'src/mesa/drivers/x11')
-rw-r--r-- | src/mesa/drivers/x11/xm_dd.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/mesa/drivers/x11/xm_dd.c b/src/mesa/drivers/x11/xm_dd.c index 0aa47d55e46..fec4f5d0388 100644 --- a/src/mesa/drivers/x11/xm_dd.c +++ b/src/mesa/drivers/x11/xm_dd.c @@ -440,10 +440,15 @@ xmesa_clear(struct pipe_context *pipe, GLboolean color, GLboolean depth, GLboolean stencil, GLboolean accum) { struct softpipe_context *sp = (struct softpipe_context *) pipe; + + /* Clear non-color buffers first. This will cause softpipe to + * re-validate the scissor/surface bounds. + */ + softpipe_clear(pipe, GL_FALSE, depth, stencil, accum); + if (color) { GET_CURRENT_CONTEXT(ctx); GLuint i; - softpipe_update_derived(sp); for (i = 0; i < sp->framebuffer.num_cbufs; i++) { struct pipe_surface *ps = sp->framebuffer.cbufs[i]; struct xmesa_renderbuffer *xrb = (struct xmesa_renderbuffer *) ps->rb; @@ -453,10 +458,8 @@ xmesa_clear(struct pipe_context *pipe, GLboolean color, GLboolean depth, const GLint h = sp->cliprect.maxy - y; xrb->clearFunc(ctx, xrb, x, y, w, h); } - color = GL_FALSE; } - softpipe_clear(pipe, color, depth, stencil, accum); } |