mesa/ff_shader: Fix sampler state reading
mesa/ff_shader: Fix sampler state reading

Fixed function fragment shader generator was incorrectly read texture
sampling state directly from texture object. To make sure that
ARB_sampler_object works correctly shader generator has to use the
bound sampler if one exist.

Signed-off-by: Pauli Nieminen <1553d7c37f170f05cc446e658e701b123a72a5e4@linux.intel.com>
Reviewed-by: Brian Paul <3cb4e1df5ec4da2c7c4af7c52cec8cf340a55a10@vmware.com>
Reviewed-by: Eric Anholt <96f164ad4d9b2b0dacf8ebee2bb1eeb3aa69adf1@anholt.net>

zz85/glsl-optimizer,benaadams/glsl-optimizer,djreep81/glsl-optimizer,benaadams/glsl-optimizer,mcanthony/glsl-optimizer,jbarczak/glsl-optimizer,zeux/glsl-optimizer,tokyovigilante/glsl-optimizer,mcanthony/glsl-optimizer,zz85/glsl-optimizer,mcanthony/glsl-optimizer,mapbox/glsl-optimizer,benaadams/glsl-optimizer,mapbox/glsl-optimizer,tokyovigilante/glsl-optimizer,djreep81/glsl-optimizer,dellis1972/glsl-optimizer,tokyovigilante/glsl-optimizer,bkaradzic/glsl-optimizer,tokyovigilante/glsl-optimizer,metora/MesaGLSLCompiler,zeux/glsl-optimizer,mapbox/glsl-optimizer,jbarczak/glsl-optimizer,wolf96/glsl-optimizer,jbarczak/glsl-optimizer,zz85/glsl-optimizer,dellis1972/glsl-optimizer,dellis1972/glsl-optimizer,djreep81/glsl-optimizer,zeux/glsl-optimizer,bkaradzic/glsl-optimizer,bkaradzic/glsl-optimizer,jbarczak/glsl-optimizer,wolf96/glsl-optimizer,zeux/glsl-optimizer,djreep81/glsl-optimizer,zz85/glsl-optimizer,wolf96/glsl-optimizer,wolf96/glsl-optimizer,jbarczak/glsl-optimizer,benaadams/glsl-optimizer,wolf96/glsl-optimizer,bkaradzic/glsl-optimizer,metora/MesaGLSLCompiler,djreep81/glsl-optimizer,mcanthony/glsl-optimizer,zz85/glsl-optimizer,mcanthony/glsl-optimizer,mapbox/glsl-optimizer,zeux/glsl-optimizer,dellis1972/glsl-optimizer,benaadams/glsl-optimizer,bkaradzic/glsl-optimizer,benaadams/glsl-optimizer,metora/MesaGLSLCompiler,tokyovigilante/glsl-optimizer,mapbox/glsl-optimizer,zz85/glsl-optimizer,dellis1972/glsl-optimizer