summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian <brian.paul@tungstengraphics.com>2007-12-07 07:53:06 -0700
committerBen Skeggs <skeggsb@gmail.com>2007-12-09 12:05:26 +1100
commita09224258a205dbb99eae2c9f94fce8d4f3f73f6 (patch)
tree88a668c5941c16ce2e5cfc206974b3f044d37b69
parent6cb181dc15116fb495a8f68d4088ecb15dc39c0f (diff)
move surface pitch calculation so it always gets updated
-rw-r--r--src/mesa/state_tracker/st_cb_fbo.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_cb_fbo.c b/src/mesa/state_tracker/st_cb_fbo.c
index 6b9023c410..0ee5f45aae 100644
--- a/src/mesa/state_tracker/st_cb_fbo.c
+++ b/src/mesa/state_tracker/st_cb_fbo.c
@@ -105,10 +105,11 @@ st_renderbuffer_alloc_storage(GLcontext * ctx, struct gl_renderbuffer *rb,
if (!strb->surface)
return GL_FALSE;
strb->surface->cpp = cpp;
- strb->surface->pitch = pipe->winsys->surface_pitch(pipe->winsys, cpp,
- width, flags);
}
+ strb->surface->pitch = pipe->winsys->surface_pitch(pipe->winsys, cpp,
+ width, flags);
+
/* loop here since mapping is refcounted */
while (strb->surface->map)
pipe_surface_unmap(strb->surface);