mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-27 13:53:18 +00:00
shader_recompiler: Emulate unnormalized sampler coordinates in shader. (#1762)
* shader_recompiler: Emulate unnormalized sampler coordinates in shader. * Address review comments.
This commit is contained in:
parent
306279901f
commit
028be3ba5d
10 changed files with 78 additions and 12 deletions
|
@ -692,6 +692,20 @@ F32F64 IREmitter::FPMul(const F32F64& a, const F32F64& b) {
|
|||
}
|
||||
}
|
||||
|
||||
F32F64 IREmitter::FPDiv(const F32F64& a, const F32F64& b) {
|
||||
if (a.Type() != b.Type()) {
|
||||
UNREACHABLE_MSG("Mismatching types {} and {}", a.Type(), b.Type());
|
||||
}
|
||||
switch (a.Type()) {
|
||||
case Type::F32:
|
||||
return Inst<F32>(Opcode::FPDiv32, a, b);
|
||||
case Type::F64:
|
||||
return Inst<F64>(Opcode::FPDiv64, a, b);
|
||||
default:
|
||||
ThrowInvalidType(a.Type());
|
||||
}
|
||||
}
|
||||
|
||||
F32F64 IREmitter::FPFma(const F32F64& a, const F32F64& b, const F32F64& c) {
|
||||
if (a.Type() != b.Type() || a.Type() != c.Type()) {
|
||||
UNREACHABLE_MSG("Mismatching types {}, {}, and {}", a.Type(), b.Type(), c.Type());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue