mirror of
https://github.com/lubosz/overte.git
synced 2025-04-24 00:13:53 +02:00
CLean up the shader code for the blinn and the new PBR shading equation
This commit is contained in:
parent
ed8d433ad5
commit
871f9a849a
1 changed files with 1 additions and 2 deletions
|
@ -28,8 +28,7 @@ vec4 evalPBRShading(vec3 fragNormal, vec3 fragLightDir, vec3 fragEyeDir, vec3 sp
|
|||
float shlickPower = (1.0 - dot(fragLightDir,halfDir));
|
||||
float shlickPower2 = shlickPower * shlickPower;
|
||||
float shlickPower5 = shlickPower2 * shlickPower2 * shlickPower;
|
||||
// vec3 schlick = specular * (1.0 - shlickPower5) + vec3(shlickPower5);
|
||||
vec3 schlick = vec3(0.21) * (1.0 - shlickPower5) + vec3(shlickPower5);
|
||||
vec3 schlick = specular * (1.0 - shlickPower5) + vec3(shlickPower5);
|
||||
vec3 reflect = specularPower * schlick;
|
||||
|
||||
return vec4(reflect, diffuse);
|
||||
|
|
Loading…
Reference in a new issue