hch
2025-09-15 e9fb1742f33914effd247c644d0abc3ef1ffa6c5
0312 描边调细
1个文件已修改
2 ■■■ 已修改文件
Shader/OutlineEx.shader 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
Shader/OutlineEx.shader
@@ -134,7 +134,7 @@
                const fixed sinArray[12] = { 0, 0.5, 0.866, 1, 0.866, 0.5, 0, -0.5, -0.866, -1, -0.866, -0.5 };
                const fixed cosArray[12] = { 1, 0.866, 0.5, 0, -0.5, -0.866, -1, -0.866, -0.5, 0, 0.5, 0.866 };
                float2 pos = IN.texcoord + _MainTex_TexelSize.xy * float2(cosArray[pIndex], sinArray[pIndex]) * IN.normal.z*0.2;    //normal.z 存放 _OutlineWidth
                float2 pos = IN.texcoord + _MainTex_TexelSize.xy * float2(cosArray[pIndex], sinArray[pIndex]) * IN.normal.z*0.12;    //normal.z 存放 _OutlineWidth
                return IsInRect(pos, IN.uv1, IN.uv2) * (tex2D(_MainTex, pos) + _TextureSampleAdd).w * IN.tangent.w;        //tangent.w  存放 _OutlineColor.w
            }