Archived
1
Fork 0

Don't clamp NdotV in surface calculations

This commit is contained in:
redstrate 2020-08-14 22:31:21 -04:00
parent 82a7d41dbc
commit f52fedc778

View file

@ -13,7 +13,7 @@ ComputedSurfaceInfo compute_surface(const vec3 diffuse, const vec3 normal, const
info.N = normalize(normal);
info.V = normalize(scene.camPos.xyz - in_frag_pos);
info.NdotV = clamp(dot(info.N, info.V), 0.0, 1.0);
info.NdotV = max(dot(info.N, info.V), 0.0);
info.metallic = metallic;
info.roughness = max(0.0001, roughness * roughness);