summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r300/r300_emit.c
diff options
context:
space:
mode:
authorMarek Olšák <maraeo@gmail.com>2010-03-19 01:13:57 +0100
committerMarek Olšák <maraeo@gmail.com>2010-03-19 04:09:07 +0100
commitafae0891949b72a2ede2a3b6a01d4d6bcf4ceae0 (patch)
tree6e75eafbe05d39c5ec470484db17eb7317403959 /src/gallium/drivers/r300/r300_emit.c
parentf6e987ce7839d66edb88403d2c9ac1b28db2832b (diff)
r300g: fix breakage after the gallium-sampler-view merge
Diffstat (limited to 'src/gallium/drivers/r300/r300_emit.c')
-rw-r--r--src/gallium/drivers/r300/r300_emit.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gallium/drivers/r300/r300_emit.c b/src/gallium/drivers/r300/r300_emit.c
index 5522fb306d..c897df628d 100644
--- a/src/gallium/drivers/r300/r300_emit.c
+++ b/src/gallium/drivers/r300/r300_emit.c
@@ -1050,9 +1050,11 @@ validate:
}
/* ...textures... */
for (i = 0; i < texstate->count; i++) {
- tex = (struct r300_texture*)texstate->fragment_sampler_views[i]->texture;
- if (!tex || !texstate->sampler_states[i])
+ if (!(texstate->tx_enable & (1 << i))) {
continue;
+ }
+
+ tex = (struct r300_texture*)texstate->fragment_sampler_views[i]->texture;
if (!r300_add_texture(r300->rws, tex,
RADEON_GEM_DOMAIN_GTT | RADEON_GEM_DOMAIN_VRAM, 0)) {
r300->context.flush(&r300->context, 0, NULL);