赞
踩
找到Library/PackageCache/com.esotericsoftware.spine.spine-unity@dab0545c1b/Runtime/spine-unity/Shaders/SkeletonGraphic/CGIncludes/Spine-SkeletonGraphic-NormalPass.cginc
将下面部分
fixed4 frag (VertexOutput IN) : SV_Target { half4 texColor = tex2D(_MainTex, IN.texcoord); #if defined(_STRAIGHT_ALPHA_INPUT) texColor.rgb *= texColor.a; #endif half4 color = (texColor + _TextureSampleAdd) * IN.color; color *= UnityGet2DClipping(IN.worldPosition.xy, _ClipRect); #ifdef UNITY_UI_ALPHACLIP clip (color.a - 0.001); #endif return color; }
替换为
fixed4 frag (VertexOutput IN) : SV_Target
{
half4 texColor = tex2D(_MainTex, IN.texcoord);
texColor.rgb *= texColor.a;
half4 color = (texColor + _TextureSampleAdd) * IN.color;
color *= UnityGet2DClipping(IN.worldPosition.xy, _ClipRect);
#ifdef UNITY_UI_ALPHACLIP
clip (color.a - 0.001);
#endif
return color;
}
完成!注意一般不能直接修改,要先复制到新的shader中修改。
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。