diff options
| author | 2021-03-26 19:24:50 +0100 | |
|---|---|---|
| committer | 2021-07-22 21:51:24 -0400 | |
| commit | b5db38f50e9f81964bf0cc946e4ed5b00fe564d0 (patch) | |
| tree | fefc872d1da6481c8478e4da0381faaaad6f4b75 /src/shader_recompiler/frontend/ir/ir_emitter.cpp | |
| parent | shader: Implement TLD4.PTP (diff) | |
| download | yuzu-b5db38f50e9f81964bf0cc946e4ed5b00fe564d0.tar.gz yuzu-b5db38f50e9f81964bf0cc946e4ed5b00fe564d0.tar.xz yuzu-b5db38f50e9f81964bf0cc946e4ed5b00fe564d0.zip | |
shader: Add IR opcode for ImageFetch
Diffstat (limited to 'src/shader_recompiler/frontend/ir/ir_emitter.cpp')
| -rw-r--r-- | src/shader_recompiler/frontend/ir/ir_emitter.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/shader_recompiler/frontend/ir/ir_emitter.cpp b/src/shader_recompiler/frontend/ir/ir_emitter.cpp index f49c30484..b8d36f362 100644 --- a/src/shader_recompiler/frontend/ir/ir_emitter.cpp +++ b/src/shader_recompiler/frontend/ir/ir_emitter.cpp | |||
| @@ -1491,6 +1491,12 @@ Value IREmitter::ImageGatherDref(const Value& handle, const Value& coords, const | |||
| 1491 | return Inst(op, Flags{info}, handle, coords, offset, offset2, dref); | 1491 | return Inst(op, Flags{info}, handle, coords, offset, offset2, dref); |
| 1492 | } | 1492 | } |
| 1493 | 1493 | ||
| 1494 | Value IREmitter::ImageFetch(const Value& handle, const Value& coords, const Value& offset, | ||
| 1495 | const U32& lod, const U32& multisampling, TextureInstInfo info) { | ||
| 1496 | const Opcode op{handle.IsImmediate() ? Opcode::BoundImageFetch : Opcode::BindlessImageFetch}; | ||
| 1497 | return Inst(op, Flags{info}, handle, coords, offset, lod, multisampling); | ||
| 1498 | } | ||
| 1499 | |||
| 1494 | U1 IREmitter::VoteAll(const U1& value) { | 1500 | U1 IREmitter::VoteAll(const U1& value) { |
| 1495 | return Inst<U1>(Opcode::VoteAll, value); | 1501 | return Inst<U1>(Opcode::VoteAll, value); |
| 1496 | } | 1502 | } |