gallivm: fix lp_build_sample_compare()
authorBrian Paul <brianp@vmware.com>
Tue, 21 Sep 2010 21:25:31 +0000 (15:25 -0600)
committerBrian Paul <brianp@vmware.com>
Tue, 21 Sep 2010 21:31:32 +0000 (15:31 -0600)
commitffa2d203fb71d54dc8dfa5d17aa1637d2f2bb5b5
tree244f98db3eb5a51f80d7ee1d44f48959b907cd1f
parent83ea4878db8768b6e8444492009d80247d4374b7
gallivm: fix lp_build_sample_compare()

The old code didn't really make sense.  We only need to compare the
X channel of the texture (depth) against the texcoord.

For (bi)linear sampling we should move the calls to this function
and compute the final result as (s1+s2+s3+s4) * 0.25.  Someday.

This fixes the glean glsl1 shadow2D() tests.  See fd.o bug 29307.
src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c