summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r300/r300_texture_desc.c
diff options
context:
space:
mode:
authorMarek Olšák <maraeo@gmail.com>2010-07-24 23:05:40 +0200
committerMarek Olšák <maraeo@gmail.com>2010-07-25 10:25:21 +0200
commit49330fc5ac13e25cb201e62995329cffaf5046f0 (patch)
treee5cf700875018050f378a75cacc8b79cb3ae6e3e /src/gallium/drivers/r300/r300_texture_desc.c
parentc92d232061c1aef6f5f56cbd815625778db2fd8c (diff)
downloadexternal_mesa3d-49330fc5ac13e25cb201e62995329cffaf5046f0.zip
external_mesa3d-49330fc5ac13e25cb201e62995329cffaf5046f0.tar.gz
external_mesa3d-49330fc5ac13e25cb201e62995329cffaf5046f0.tar.bz2
r300g: do not use TXPITCH_EN if the width is POT and the height is NPOT
Diffstat (limited to 'src/gallium/drivers/r300/r300_texture_desc.c')
-rw-r--r--src/gallium/drivers/r300/r300_texture_desc.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/r300/r300_texture_desc.c b/src/gallium/drivers/r300/r300_texture_desc.c
index becaa59..02591aa 100644
--- a/src/gallium/drivers/r300/r300_texture_desc.c
+++ b/src/gallium/drivers/r300/r300_texture_desc.c
@@ -272,6 +272,10 @@ static void r300_setup_flags(struct r300_texture_desc *desc)
(desc->stride_in_bytes_override &&
stride_to_width(desc->b.b.format,
desc->stride_in_bytes_override) != desc->b.b.width0);
+
+ desc->is_npot =
+ desc->uses_stride_addressing ||
+ !util_is_power_of_two(desc->b.b.height0);
}
static void r300_setup_cbzb_flags(struct r300_screen *rscreen,