summaryrefslogtreecommitdiffstats
path: root/src/video_core/engines
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2018-06-03 18:05:38 +0200
committerGitHub <noreply@github.com>2018-06-03 18:05:38 +0200
commitbb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595 (patch)
treed75cdd5f1f50dc9e32e0ca28e167c1680f8f75d8 /src/video_core/engines
parentMerge pull request #495 from bunnei/improve-rro (diff)
parentgl_shader_decompiler: Implement TEX instruction. (diff)
downloadyuzu-bb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595.tar
yuzu-bb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595.tar.gz
yuzu-bb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595.tar.bz2
yuzu-bb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595.tar.lz
yuzu-bb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595.tar.xz
yuzu-bb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595.tar.zst
yuzu-bb9d39b8fe89c7619ffbca2a0a6ecae1eb3f4595.zip
Diffstat (limited to 'src/video_core/engines')
-rw-r--r--src/video_core/engines/shader_bytecode.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/video_core/engines/shader_bytecode.h b/src/video_core/engines/shader_bytecode.h
index 26c891356..fd4e0746e 100644
--- a/src/video_core/engines/shader_bytecode.h
+++ b/src/video_core/engines/shader_bytecode.h
@@ -261,6 +261,19 @@ union Instruction {
BitField<50, 1, u64> saturate_a;
} conversion;
+ union {
+ BitField<31, 4, u64> component_mask;
+
+ bool IsComponentEnabled(size_t component) const {
+ return ((1 << component) & component_mask) != 0;
+ }
+ } tex;
+
+ union {
+ // TODO(bunnei): This is just a guess, needs to be verified
+ BitField<52, 1, u64> enable_g_component;
+ } texs;
+
BitField<61, 1, u64> is_b_imm;
BitField<60, 1, u64> is_b_gpr;
BitField<59, 1, u64> is_c_gpr;
@@ -281,6 +294,7 @@ public:
KIL,
LD_A,
ST_A,
+ TEX,
TEXQ, // Texture Query
TEXS, // Texture Fetch with scalar/non-vec4 source/destinations
TLDS, // Texture Load with scalar/non-vec4 source/destinations
@@ -444,6 +458,7 @@ private:
INST("111000110011----", Id::KIL, Type::Flow, "KIL"),
INST("1110111111011---", Id::LD_A, Type::Memory, "LD_A"),
INST("1110111111110---", Id::ST_A, Type::Memory, "ST_A"),
+ INST("1100000000111---", Id::TEX, Type::Memory, "TEX"),
INST("1101111101001---", Id::TEXQ, Type::Memory, "TEXQ"),
INST("1101100---------", Id::TEXS, Type::Memory, "TEXS"),
INST("1101101---------", Id::TLDS, Type::Memory, "TLDS"),