From d0d845ab2a3c8c2878da07c9c0be4fad151ce1fb Mon Sep 17 00:00:00 2001 From: Masataka SUMI Date: Fri, 4 Nov 2022 21:48:54 +0900 Subject: [PATCH] Remove supporting legacy vrm shaders. --- .../Export/BuiltInVrmMaterialExporter.cs | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/Assets/VRM/Runtime/IO/MaterialIO/BuiltInRP/Export/BuiltInVrmMaterialExporter.cs b/Assets/VRM/Runtime/IO/MaterialIO/BuiltInRP/Export/BuiltInVrmMaterialExporter.cs index 82d26e25c..9b3f99216 100644 --- a/Assets/VRM/Runtime/IO/MaterialIO/BuiltInRP/Export/BuiltInVrmMaterialExporter.cs +++ b/Assets/VRM/Runtime/IO/MaterialIO/BuiltInRP/Export/BuiltInVrmMaterialExporter.cs @@ -10,33 +10,16 @@ namespace VRM public static readonly string[] SupportedShaderNames = { BuiltInVrmMToonMaterialExporter.TargetShaderName, - "VRM/UnlitTexture", - "VRM/UnlitTransparent", - "VRM/UnlitCutout", - "VRM/UnlitTransparentZWrite", }; private readonly BuiltInGltfMaterialExporter _gltfExporter = new BuiltInGltfMaterialExporter(); public glTFMaterial ExportMaterial(Material src, ITextureExporter textureExporter, GltfExportSettings settings) { - glTFMaterial dst = default; switch (src.shader.name) { case BuiltInVrmMToonMaterialExporter.TargetShaderName: - if (BuiltInVrmMToonMaterialExporter.TryExportMaterial(src, textureExporter, out dst)) return dst; - break; - case "VRM/UnlitTexture": - if (BuiltInGenericUnlitMaterialExporter.TryExportMaterial(src, glTFBlendMode.OPAQUE, textureExporter, out dst)) return dst; - break; - case "VRM/UnlitTransparent": - if (BuiltInGenericUnlitMaterialExporter.TryExportMaterial(src, glTFBlendMode.BLEND, textureExporter, out dst)) return dst; - break; - case "VRM/UnlitCutout": - if (BuiltInGenericUnlitMaterialExporter.TryExportMaterial(src, glTFBlendMode.MASK, textureExporter, out dst)) return dst; - break; - case "VRM/UnlitTransparentZWrite": - if (BuiltInGenericUnlitMaterialExporter.TryExportMaterial(src, glTFBlendMode.BLEND, textureExporter, out dst)) return dst; + if (BuiltInVrmMToonMaterialExporter.TryExportMaterial(src, textureExporter, out var dst)) return dst; break; }