Enable SPIR-V backend by default

This commit is contained in:
gdk 2022-04-08 22:55:25 -03:00 committed by riperiperi
parent f16b47114c
commit 3bac0b872c
2 changed files with 4 additions and 2 deletions

View file

@ -60,6 +60,6 @@ namespace Ryujinx.Graphics.Gpu
/// <summary>
/// Enables or disables shader SPIR-V compilation.
/// </summary>
public static bool EnableSpirvCompilation;
public static bool EnableSpirvCompilationOnVulkan = true;
}
}

View file

@ -688,7 +688,9 @@ namespace Ryujinx.Graphics.Gpu.Shader
private static TranslationOptions CreateTranslationOptions(TargetApi api, TranslationFlags flags)
{
TargetLanguage lang = GraphicsConfig.EnableSpirvCompilation ? TargetLanguage.Spirv : TargetLanguage.Glsl;
TargetLanguage lang = GraphicsConfig.EnableSpirvCompilationOnVulkan && api == TargetApi.Vulkan
? TargetLanguage.Spirv
: TargetLanguage.Glsl;
return new TranslationOptions(lang, api, flags);
}