diff options
author | Keith Whitwell <[email protected]> | 2007-12-11 14:39:37 +0000 |
---|---|---|
committer | Keith Whitwell <[email protected]> | 2007-12-11 14:39:37 +0000 |
commit | c3af68dc5022715cc8f126b7df12f3f5248aefe7 (patch) | |
tree | 587d4fbb480ad63d9326f6d214414b2a7bbee67d /src/mesa/pipe/softpipe | |
parent | 94cadef31f9d4ee9fce1bfa66fabb0a403a6f049 (diff) |
gallium: remove set_sampler_units interface
The effect of this mapping can be acheived by the state tracker and
setting up the pipe texture state pointers to incorporate its affects.
Diffstat (limited to 'src/mesa/pipe/softpipe')
-rw-r--r-- | src/mesa/pipe/softpipe/sp_context.c | 3 | ||||
-rw-r--r-- | src/mesa/pipe/softpipe/sp_context.h | 1 | ||||
-rw-r--r-- | src/mesa/pipe/softpipe/sp_quad_fs.c | 3 | ||||
-rw-r--r-- | src/mesa/pipe/softpipe/sp_state.h | 5 | ||||
-rw-r--r-- | src/mesa/pipe/softpipe/sp_state_sampler.c | 17 |
5 files changed, 6 insertions, 23 deletions
diff --git a/src/mesa/pipe/softpipe/sp_context.c b/src/mesa/pipe/softpipe/sp_context.c index 43f23dc1e85..7d243aaabb5 100644 --- a/src/mesa/pipe/softpipe/sp_context.c +++ b/src/mesa/pipe/softpipe/sp_context.c @@ -307,9 +307,8 @@ struct pipe_context *softpipe_create( struct pipe_winsys *pipe_winsys, softpipe->pipe.set_constant_buffer = softpipe_set_constant_buffer; softpipe->pipe.set_framebuffer_state = softpipe_set_framebuffer_state; softpipe->pipe.set_polygon_stipple = softpipe_set_polygon_stipple; - softpipe->pipe.set_sampler_units = softpipe_set_sampler_units; softpipe->pipe.set_scissor_state = softpipe_set_scissor_state; - softpipe->pipe.set_texture_state = softpipe_set_texture_state; + softpipe->pipe.set_sampler_texture = softpipe_set_sampler_texture; softpipe->pipe.set_viewport_state = softpipe_set_viewport_state; softpipe->pipe.set_vertex_buffer = softpipe_set_vertex_buffer; diff --git a/src/mesa/pipe/softpipe/sp_context.h b/src/mesa/pipe/softpipe/sp_context.h index 45d15c720e0..afdd0ec88ef 100644 --- a/src/mesa/pipe/softpipe/sp_context.h +++ b/src/mesa/pipe/softpipe/sp_context.h @@ -91,7 +91,6 @@ struct softpipe_context { struct pipe_viewport_state viewport; struct pipe_vertex_buffer vertex_buffer[PIPE_ATTRIB_MAX]; struct pipe_vertex_element vertex_element[PIPE_ATTRIB_MAX]; - uint sampler_units[PIPE_MAX_SAMPLERS]; unsigned dirty; /* diff --git a/src/mesa/pipe/softpipe/sp_quad_fs.c b/src/mesa/pipe/softpipe/sp_quad_fs.c index 75576a9bde8..9307ed233d0 100644 --- a/src/mesa/pipe/softpipe/sp_quad_fs.c +++ b/src/mesa/pipe/softpipe/sp_quad_fs.c @@ -98,7 +98,6 @@ shade_quad( /* Consts does not require 16 byte alignment. */ machine->Consts = softpipe->mapped_constants[PIPE_SHADER_FRAGMENT]; - machine->SamplerUnits = softpipe->sampler_units; machine->InterpCoefs = quad->coef; machine->Inputs[0].xyzw[0].f[0] = fx; @@ -206,7 +205,7 @@ shade_quad_llvm(struct quad_stage *qs, /*quad->mask &=*/ gallivm_fragment_shader_exec(llvm, fx, fy, dests, inputs, softpipe->mapped_constants[PIPE_SHADER_FRAGMENT], - qss->samplers, softpipe->sampler_units); + qss->samplers); #if DLLVM printf("OUT LLVM = 1[%f %f %f %f], 2[%f %f %f %f]\n", dests[0][0][0], dests[0][0][1], dests[0][0][2], dests[0][0][3], diff --git a/src/mesa/pipe/softpipe/sp_state.h b/src/mesa/pipe/softpipe/sp_state.h index 80a1cba25ad..a3bd078a718 100644 --- a/src/mesa/pipe/softpipe/sp_state.h +++ b/src/mesa/pipe/softpipe/sp_state.h @@ -111,13 +111,10 @@ void softpipe_delete_vs_state(struct pipe_context *, void *); void softpipe_set_polygon_stipple( struct pipe_context *, const struct pipe_poly_stipple * ); -void softpipe_set_sampler_units( struct pipe_context *, - uint numSamplers, const uint *units ); - void softpipe_set_scissor_state( struct pipe_context *, const struct pipe_scissor_state * ); -void softpipe_set_texture_state( struct pipe_context *, +void softpipe_set_sampler_texture( struct pipe_context *, unsigned unit, struct pipe_texture * ); diff --git a/src/mesa/pipe/softpipe/sp_state_sampler.c b/src/mesa/pipe/softpipe/sp_state_sampler.c index 173901f04e6..3842e71503b 100644 --- a/src/mesa/pipe/softpipe/sp_state_sampler.c +++ b/src/mesa/pipe/softpipe/sp_state_sampler.c @@ -67,9 +67,9 @@ softpipe_delete_sampler_state(struct pipe_context *pipe, void -softpipe_set_texture_state(struct pipe_context *pipe, - unsigned unit, - struct pipe_texture *texture) +softpipe_set_sampler_texture(struct pipe_context *pipe, + unsigned unit, + struct pipe_texture *texture) { struct softpipe_context *softpipe = softpipe_context(pipe); @@ -82,15 +82,4 @@ softpipe_set_texture_state(struct pipe_context *pipe, } -void -softpipe_set_sampler_units(struct pipe_context *pipe, - uint num_samplers, const uint *units ) -{ - struct softpipe_context *softpipe = softpipe_context(pipe); - uint i; - for (i = 0; i < num_samplers; i++) - softpipe->sampler_units[i] = units[i]; - softpipe->dirty |= SP_NEW_SAMPLER; -} - |