radeonsi: support constants as TEX coordinates

Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
(cherry picked from commit 8514f5ac01)
This commit is contained in:
Christian König 2013-02-04 17:46:42 +01:00 committed by Michel Dänzer
parent 38e728498b
commit f50e4e21f4

View file

@ -433,6 +433,15 @@ static LLVMValueRef fetch_constant(
LLVMValueRef offset;
LLVMValueRef load;
if (swizzle == LP_CHAN_ALL) {
unsigned chan;
LLVMValueRef values[4];
for (chan = 0; chan < TGSI_NUM_CHANNELS; ++chan)
values[chan] = fetch_constant(bld_base, reg, type, chan);
return lp_build_gather_values(bld_base->base.gallivm, values, 4);
}
/* currently not supported */
if (reg->Register.Indirect) {
assert(0);