mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-11-22 14:52:45 +01:00
Merge pull request #3338 from ReinUsesLisp/no-fastmath
gl_shader_cache: Disable fastmath on Nvidia
This commit is contained in:
commit
9c6b5cae68
1 changed files with 4 additions and 0 deletions
|
@ -260,6 +260,10 @@ CachedProgram BuildShader(const Device& device, u64 unique_identifier, ShaderTyp
|
|||
"#extension GL_NV_shader_thread_group : require\n"
|
||||
"#extension GL_NV_shader_thread_shuffle : require\n";
|
||||
}
|
||||
// This pragma stops Nvidia's driver from over optimizing math (probably using fp16 operations)
|
||||
// on places where we don't want to.
|
||||
// Thanks to Ryujinx for finding this workaround.
|
||||
source += "#pragma optionNV(fastmath off)\n";
|
||||
|
||||
if (shader_type == ShaderType::Geometry) {
|
||||
const auto [glsl_topology, max_vertices] = GetPrimitiveDescription(variant.primitive_mode);
|
||||
|
|
Loading…
Reference in a new issue