summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2008-03-13 13:22:24 -0600
committerBrian Paul <brian.paul@tungstengraphics.com>2008-03-13 13:22:51 -0600
commit7ffbaebce1da7fec36a38f424f266806a3a0fc6a (patch)
treedf89116cd7a3c85ef9083443147563d0e9142cbc /src
parentcb294542bcaca7d9847067ce502a68fd8e92f42e (diff)
gallium: fix bug in stip_first_tri()
Need to compute num_samplers after binding/creating the fragment shader.
Diffstat (limited to 'src')
-rw-r--r--src/gallium/auxiliary/draw/draw_pstipple.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gallium/auxiliary/draw/draw_pstipple.c b/src/gallium/auxiliary/draw/draw_pstipple.c
index d7475b457c..08f06bf222 100644
--- a/src/gallium/auxiliary/draw/draw_pstipple.c
+++ b/src/gallium/auxiliary/draw/draw_pstipple.c
@@ -488,16 +488,16 @@ pstip_first_tri(struct draw_stage *stage, struct prim_header *header)
struct pipe_context *pipe = pstip->pipe;
uint num_samplers;
- /* how many samplers? */
- /* we'll use sampler/texture[pstip->sampler_unit] for the stipple */
- num_samplers = MAX2(pstip->num_textures, pstip->num_samplers);
- num_samplers = MAX2(num_samplers, pstip->sampler_unit + 1);
-
assert(stage->draw->rasterizer->poly_stipple_enable);
/* bind our fragprog */
bind_pstip_fragment_shader(pstip);
+ /* how many samplers? */
+ /* we'll use sampler/texture[pstip->sampler_unit] for the stipple */
+ num_samplers = MAX2(pstip->num_textures, pstip->num_samplers);
+ num_samplers = MAX2(num_samplers, pstip->sampler_unit + 1);
+
/* plug in our sampler, texture */
pstip->state.samplers[pstip->sampler_unit] = pstip->sampler_cso;
pstip->state.textures[pstip->sampler_unit] = pstip->texture;