Merge branch 'Muzz-Triplanar-Features' into 1.10

This commit is contained in:
Muzz
2025-02-28 14:54:44 +01:00
committed by Wojtek Figat
parent dad8c0cd6b
commit 7885590593
14 changed files with 536 additions and 55 deletions

View File

@@ -261,6 +261,14 @@ struct GBufferOutput
float4 RT3 : SV_Target4;
};
float3 UnpackNormalMap(float2 value)
{
float3 normal;
normal.xy = value * 2.0 - 1.0;
normal.z = sqrt(saturate(1.0 - dot(normal.xy, normal.xy)));
return normal;
}
float3x3 CalcTangentBasis(float3 normal, float3 pos, float2 uv)
{
// References: