mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-24 23:11:14 +01:00
Merge pull request #13088 from TellowKrinkle/iOSFixes
VideoBackends:Metal: Fix bbox on newer iOS devices
This commit is contained in:
commit
ae14abb2fa
@ -309,7 +309,7 @@ void Metal::Util::PopulateBackendInfoFeatures(VideoConfig* config, id<MTLDevice>
|
|||||||
{
|
{
|
||||||
// Requires SIMD-scoped reduction operations
|
// Requires SIMD-scoped reduction operations
|
||||||
g_features.subgroup_ops =
|
g_features.subgroup_ops =
|
||||||
[device supportsFamily:MTLGPUFamilyMac2] || [device supportsFamily:MTLGPUFamilyApple6];
|
[device supportsFamily:MTLGPUFamilyMac2] || [device supportsFamily:MTLGPUFamilyApple7];
|
||||||
config->backend_info.bSupportsFramebufferFetch = [device supportsFamily:MTLGPUFamilyApple1];
|
config->backend_info.bSupportsFramebufferFetch = [device supportsFamily:MTLGPUFamilyApple1];
|
||||||
}
|
}
|
||||||
if (g_features.subgroup_ops)
|
if (g_features.subgroup_ops)
|
||||||
@ -559,6 +559,9 @@ std::optional<std::string> Metal::Util::TranslateShaderToMSL(ShaderStage stage,
|
|||||||
options.platform = spirv_cross::CompilerMSL::Options::macOS;
|
options.platform = spirv_cross::CompilerMSL::Options::macOS;
|
||||||
#elif TARGET_OS_IOS
|
#elif TARGET_OS_IOS
|
||||||
options.platform = spirv_cross::CompilerMSL::Options::iOS;
|
options.platform = spirv_cross::CompilerMSL::Options::iOS;
|
||||||
|
// Otherwise SPIRV-Cross will try to compile subgroup ops to quad ops instead
|
||||||
|
// (And crash because there's no quad_min or quad_max)
|
||||||
|
options.ios_use_simdgroup_functions = Metal::g_features.subgroup_ops;
|
||||||
#else
|
#else
|
||||||
#error What platform is this?
|
#error What platform is this?
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user