summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/tgsi
diff options
context:
space:
mode:
authorRoland Scheidegger <[email protected]>2017-09-05 17:59:37 +0200
committerRoland Scheidegger <[email protected]>2017-09-07 03:32:01 +0200
commit6d9d6071ee961acc82543b321764a0ffec8cd39a (patch)
treee0b3744fd64e0a629e46642e9d47abe990554ae0 /src/gallium/auxiliary/tgsi
parentde6810d9be9d1e6426881774458f8a6f3bed17ee (diff)
llvmpipe, tgsi: hook up dx10 gather4 opcode
Trivial. We already support tg4 for legacy tex opcodes, so the actual texture sampling code already handles it. (Just like TG4, we don't handle additional capabilities and always sample red channel.) Reviewed-by: Jose Fonseca <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/tgsi')
-rw-r--r--src/gallium/auxiliary/tgsi/tgsi_exec.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/tgsi/tgsi_exec.c b/src/gallium/auxiliary/tgsi/tgsi_exec.c
index c58ea6ad09c..1264df0c622 100644
--- a/src/gallium/auxiliary/tgsi/tgsi_exec.c
+++ b/src/gallium/auxiliary/tgsi/tgsi_exec.c
@@ -2631,6 +2631,9 @@ exec_sample(struct tgsi_exec_machine *mach,
lod = &c1;
control = TGSI_SAMPLER_LOD_EXPLICIT;
}
+ else if (modifier == TEX_MODIFIER_GATHER) {
+ control = TGSI_SAMPLER_GATHER;
+ }
else {
assert(modifier == TEX_MODIFIER_LEVEL_ZERO);
control = TGSI_SAMPLER_LOD_ZERO;
@@ -5687,7 +5690,7 @@ exec_instruction(
break;
case TGSI_OPCODE_GATHER4:
- assert(0);
+ exec_sample(mach, inst, TEX_MODIFIER_GATHER, FALSE);
break;
case TGSI_OPCODE_SVIEWINFO: