forked from suyu/suyu
Shaders: Log and crash when using an unimplemented texture type in a texture sampling instruction.
This commit is contained in:
parent
b1d238bbb8
commit
fc5b489b0f
1 changed files with 14 additions and 5 deletions
|
@ -1526,7 +1526,9 @@ private:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
UNIMPLEMENTED();
|
LOG_CRITICAL(HW_GPU, "Unhandled texture type {}",
|
||||||
|
static_cast<u32>(instr.tex.texture_type.Value()));
|
||||||
|
UNREACHABLE();
|
||||||
}
|
}
|
||||||
|
|
||||||
const std::string sampler =
|
const std::string sampler =
|
||||||
|
@ -1576,7 +1578,9 @@ private:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
UNIMPLEMENTED();
|
LOG_CRITICAL(HW_GPU, "Unhandled texture type {}",
|
||||||
|
static_cast<u32>(instr.texs.GetTextureType()));
|
||||||
|
UNREACHABLE();
|
||||||
}
|
}
|
||||||
const std::string sampler = GetSampler(instr.sampler, instr.texs.GetTextureType(),
|
const std::string sampler = GetSampler(instr.sampler, instr.texs.GetTextureType(),
|
||||||
instr.texs.IsArrayTexture());
|
instr.texs.IsArrayTexture());
|
||||||
|
@ -1593,7 +1597,8 @@ private:
|
||||||
switch (instr.tlds.GetTextureType()) {
|
switch (instr.tlds.GetTextureType()) {
|
||||||
case Tegra::Shader::TextureType::Texture2D: {
|
case Tegra::Shader::TextureType::Texture2D: {
|
||||||
if (instr.tlds.IsArrayTexture()) {
|
if (instr.tlds.IsArrayTexture()) {
|
||||||
UNIMPLEMENTED();
|
LOG_CRITICAL(HW_GPU, "Unhandled 2d array texture");
|
||||||
|
UNREACHABLE();
|
||||||
} else {
|
} else {
|
||||||
std::string x = regs.GetRegisterAsInteger(instr.gpr8);
|
std::string x = regs.GetRegisterAsInteger(instr.gpr8);
|
||||||
std::string y = regs.GetRegisterAsInteger(instr.gpr20);
|
std::string y = regs.GetRegisterAsInteger(instr.gpr20);
|
||||||
|
@ -1602,7 +1607,9 @@ private:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
UNIMPLEMENTED();
|
LOG_CRITICAL(HW_GPU, "Unhandled texture type {}",
|
||||||
|
static_cast<u32>(instr.tlds.GetTextureType()));
|
||||||
|
UNREACHABLE();
|
||||||
}
|
}
|
||||||
const std::string sampler = GetSampler(instr.sampler, instr.tlds.GetTextureType(),
|
const std::string sampler = GetSampler(instr.sampler, instr.tlds.GetTextureType(),
|
||||||
instr.tlds.IsArrayTexture());
|
instr.tlds.IsArrayTexture());
|
||||||
|
@ -1623,7 +1630,9 @@ private:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
UNIMPLEMENTED();
|
LOG_CRITICAL(HW_GPU, "Unhandled texture type {}",
|
||||||
|
static_cast<u32>(instr.tld4.texture_type.Value()));
|
||||||
|
UNREACHABLE();
|
||||||
}
|
}
|
||||||
|
|
||||||
const std::string sampler =
|
const std::string sampler =
|
||||||
|
|
Loading…
Reference in a new issue