From 586f15513edd509f6ea7258eca52c1038024ac07 Mon Sep 17 00:00:00 2001 From: yum Date: Mon, 30 Jun 2025 14:37:18 -0700 Subject: Simplify wrapped lighting function, fix how NoL is used in brdf --- yum_brdf.cginc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'yum_brdf.cginc') diff --git a/yum_brdf.cginc b/yum_brdf.cginc index 67c425c..364a183 100644 --- a/yum_brdf.cginc +++ b/yum_brdf.cginc @@ -129,7 +129,7 @@ float4 YumBRDF(v2f i, const YumLighting light, YumPbr pbr) { float3 diffuseColor = computeDiffuseColor(pbr.albedo, pbr.metallic); // Fd_Burley already includes 1/PI, so multiply by PI to match Unity intensities - float3 Fd = diffuseColor * Fd_Burley(pbr.roughness, NoV, NoL, LoH) * PI; + float3 Fd = diffuseColor * Fd_Burley(pbr.roughness, NoV, NoL_wrapped_d, LoH) * PI; Fd *= light.attenuation * pbr.ao; // Multiply by PI to match Unity intensities (same as Filament's implementation) -- cgit v1.2.3