diff options
author | Keith Whitwell <[email protected]> | 2009-08-20 18:36:57 +0100 |
---|---|---|
committer | Keith Whitwell <[email protected]> | 2009-08-20 18:36:57 +0100 |
commit | 00c835918259f8d41c3f74eca679a972713b11b2 (patch) | |
tree | f2dc09454abd960fdcc12451181d97b6978d6e09 /src/gallium/drivers/softpipe/sp_state_derived.c | |
parent | 0d9979d9ec5b931856d29c4ec44edb1f4931d1ac (diff) |
softpipe: allow the existing sampler routines to be hooked up directly
Let eg. sp_get_samples_rect be hooked directly in as the tgsi sampler
routine.
Add a field to determine whether this is a vertex or fragment sampling
call, and massage parameters to match the tgsi call.
Diffstat (limited to 'src/gallium/drivers/softpipe/sp_state_derived.c')
-rw-r--r-- | src/gallium/drivers/softpipe/sp_state_derived.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/drivers/softpipe/sp_state_derived.c b/src/gallium/drivers/softpipe/sp_state_derived.c index 3ed1de7e178..1f6e2ccb836 100644 --- a/src/gallium/drivers/softpipe/sp_state_derived.c +++ b/src/gallium/drivers/softpipe/sp_state_derived.c @@ -202,13 +202,14 @@ update_tgsi_samplers( struct softpipe_context *softpipe ) for (i = 0; i < PIPE_MAX_SAMPLERS; i++) { softpipe->tgsi.vert_samplers[i].sampler = softpipe->sampler[i]; softpipe->tgsi.vert_samplers[i].texture = softpipe->texture[i]; + softpipe->tgsi.frag_samplers[i].base.get_samples = sp_get_samples; } /* fragment shader samplers */ for (i = 0; i < PIPE_MAX_SAMPLERS; i++) { softpipe->tgsi.frag_samplers[i].sampler = softpipe->sampler[i]; softpipe->tgsi.frag_samplers[i].texture = softpipe->texture[i]; - softpipe->tgsi.frag_samplers[i].base.get_samples = sp_get_samples_fragment; + softpipe->tgsi.frag_samplers[i].base.get_samples = sp_get_samples; } for (i = 0; i < PIPE_MAX_SAMPLERS; i++) { |