summaryrefslogtreecommitdiff
path: root/src/gallium/drivers
diff options
context:
space:
mode:
authorKeith Whitwell <keithw@vmware.com>2010-11-11 16:20:24 +0000
committerKeith Whitwell <keithw@vmware.com>2010-11-11 16:20:24 +0000
commit7fb16423cc325efcdcf6e4954a5ac71d8f96dbf8 (patch)
treec55e70efc2bf91a53a4400c6a7aa7c982a69a0ff /src/gallium/drivers
parent8a3c181e9cc761abb647a8e813f25e3fa4441a9a (diff)
r600g: enforce minimum stride on render target texture images
Fixes piglit/fbo_readpixels since staging upload changes.
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r--src/gallium/drivers/r600/r600_texture.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/r600/r600_texture.c b/src/gallium/drivers/r600/r600_texture.c
index 56313e992d..e719f7fb98 100644
--- a/src/gallium/drivers/r600/r600_texture.c
+++ b/src/gallium/drivers/r600/r600_texture.c
@@ -169,6 +169,10 @@ static unsigned r600_texture_get_stride(struct pipe_screen *screen,
stride = util_format_get_stride(ptex->format, width);
if (chipc == EVERGREEN)
stride = align(stride, 512);
+
+ if (ptex->bind & PIPE_BIND_RENDER_TARGET)
+ stride = align(stride, 512);
+
return stride;
}