gallium: consolidate CSO sampler and sampler_view functions
authorBrian Paul <brianp@vmware.com>
Thu, 2 Aug 2012 19:02:40 +0000 (13:02 -0600)
committerBrian Paul <brianp@vmware.com>
Fri, 3 Aug 2012 13:16:35 +0000 (07:16 -0600)
commitea6f035ae90895bd4ee3247408eb179dfdf96d22
tree19df9d3c7b12cb641cea4ccb84950c09992c1732
parent350f12fb657a2ac860796c179233fa357e4bf46c
gallium: consolidate CSO sampler and sampler_view functions

Merge the vertex/fragment versions of the cso_set/save/restore_samplers()
functions.  Now we pass the shader stage (PIPE_SHADER_x) to the function
to indicate vertex/fragment/geometry samplers.  For example:

cso_single_sampler(cso, PIPE_SHADER_FRAGMENT, unit, sampler);

This results in quite a bit of code reduction, fewer CSO functions and
support for geometry shaders.

Reviewed-by: Marek Olšák <maraeo@gmail.com>
src/gallium/auxiliary/cso_cache/cso_context.c
src/gallium/auxiliary/cso_cache/cso_context.h
src/gallium/auxiliary/postprocess/pp_colors.c
src/gallium/auxiliary/postprocess/pp_init.c
src/gallium/auxiliary/postprocess/pp_mlaa.c
src/gallium/auxiliary/util/u_blit.c
src/gallium/auxiliary/util/u_gen_mipmap.c
src/mesa/state_tracker/st_atom_sampler.c
src/mesa/state_tracker/st_atom_texture.c
src/mesa/state_tracker/st_cb_bitmap.c
src/mesa/state_tracker/st_cb_drawpixels.c