We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 31eac92 commit ef4ac3dCopy full SHA for ef4ac3d
1 file changed
Packages/com.unity.render-pipelines.universal/ShaderLibrary/DBuffer.hlsl
@@ -139,7 +139,7 @@ void ApplyDecal(float4 positionCS,
139
// Always test the normal as we can have decompression artifact
140
if (decalSurfaceData.normalWS.w < 1.0)
141
{
142
- normalWS.xyz = normalize(normalWS.xyz * decalSurfaceData.normalWS.w + decalSurfaceData.normalWS.xyz);
+ normalWS.xyz = SafeNormalize(normalWS.xyz * decalSurfaceData.normalWS.w + decalSurfaceData.normalWS.xyz);
143
}
144
#endif
145
0 commit comments