From d25eb746df5fe3170ee67739836afdd4e2f7fc37 Mon Sep 17 00:00:00 2001 From: Masataka SUMI Date: Mon, 31 May 2021 20:21:17 +0900 Subject: [PATCH] Fix alpha source --- .../Resources/VRM10/vrmc_materials_mtoon_forward_fragment.hlsl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Assets/VRMShaders/VRM10/MToon10/Resources/VRM10/vrmc_materials_mtoon_forward_fragment.hlsl b/Assets/VRMShaders/VRM10/MToon10/Resources/VRM10/vrmc_materials_mtoon_forward_fragment.hlsl index 974047274..af43b1340 100644 --- a/Assets/VRMShaders/VRM10/MToon10/Resources/VRM10/vrmc_materials_mtoon_forward_fragment.hlsl +++ b/Assets/VRMShaders/VRM10/MToon10/Resources/VRM10/vrmc_materials_mtoon_forward_fragment.hlsl @@ -21,7 +21,7 @@ half4 MToonFragment(Varyings input) : SV_Target // Alpha Test #if defined(_ALPHATEST_ON) - const half rawAlpha = _Color.a; + const half rawAlpha = litColor.a; const half tmpAlpha = (rawAlpha - _Cutoff) / max(fwidth(rawAlpha), 0.00001) + 0.5; // Alpha to Coverage clip(tmpAlpha - _Cutoff); const half alpha = 1.0;