From 4e0f92014aee90b2b56a1a3934436cb272a866d2 Mon Sep 17 00:00:00 2001 From: Joshua Goins Date: Mon, 7 Feb 2022 13:07:30 -0500 Subject: [PATCH] Remove obsolete MSL ShaderLanguage option This is no longer relevant now that Metal is a unsupported GFX backend, the MSL conversion is now handled by MoltenVK --- engine/shadercompiler/include/shadercompiler.hpp | 1 - engine/shadercompiler/src/shadercompiler.cpp | 16 ---------------- 2 files changed, 17 deletions(-) diff --git a/engine/shadercompiler/include/shadercompiler.hpp b/engine/shadercompiler/include/shadercompiler.hpp index 38b6419..368a2f7 100755 --- a/engine/shadercompiler/include/shadercompiler.hpp +++ b/engine/shadercompiler/include/shadercompiler.hpp @@ -18,7 +18,6 @@ enum class ShaderStage { /// The shader language that the shader is written in. enum class ShaderLanguage { GLSL, - MSL, SPIRV }; diff --git a/engine/shadercompiler/src/shadercompiler.cpp b/engine/shadercompiler/src/shadercompiler.cpp index 2abd428..a7eeb9b 100755 --- a/engine/shadercompiler/src/shadercompiler.cpp +++ b/engine/shadercompiler/src/shadercompiler.cpp @@ -100,22 +100,6 @@ std::optional ShaderCompiler::compile(const ShaderLanguage from_la } switch(to_language) { - case ShaderLanguage::MSL: - { - spirv_cross::CompilerMSL msl(std::move(spirv)); - - spirv_cross::CompilerMSL::Options opts; - if(options.is_apple_mobile) { - opts.platform = spirv_cross::CompilerMSL::Options::Platform::iOS; - } else { - opts.platform = spirv_cross::CompilerMSL::Options::Platform::macOS; - } - opts.enable_decoration_binding = true; - - msl.set_msl_options(opts); - - return ShaderSource(msl.compile()); - } case ShaderLanguage::SPIRV: return ShaderSource(spirv); default: