[3.x] Fix a default shader specular render mode to (SCHLICK_GGX)
This commit is contained in:
parent
be22d7b013
commit
0f817e127d
2 changed files with 10 additions and 0 deletions
|
@ -1278,6 +1278,11 @@ LIGHT_SHADER_CODE
|
|||
float NdotV = dot(N, V);
|
||||
float cNdotV = max(abs(NdotV), 1e-6);
|
||||
|
||||
/* Make a default specular mode SPECULAR_SCHLICK_GGX. */
|
||||
#if !defined(SPECULAR_DISABLED) && !defined(SPECULAR_SCHLICK_GGX) && !defined(SPECULAR_BLINN) && !defined(SPECULAR_PHONG) && !defined(SPECULAR_TOON)
|
||||
#define SPECULAR_SCHLICK_GGX
|
||||
#endif
|
||||
|
||||
#if defined(DIFFUSE_BURLEY) || defined(SPECULAR_BLINN) || defined(SPECULAR_SCHLICK_GGX) || defined(LIGHT_USE_CLEARCOAT)
|
||||
vec3 H = normalize(V + L);
|
||||
#endif
|
||||
|
|
|
@ -1036,6 +1036,11 @@ LIGHT_SHADER_CODE
|
|||
float NdotV = dot(N, V);
|
||||
float cNdotV = max(NdotV, 0.0);
|
||||
|
||||
/* Make a default specular mode SPECULAR_SCHLICK_GGX. */
|
||||
#if !defined(SPECULAR_DISABLED) && !defined(SPECULAR_SCHLICK_GGX) && !defined(SPECULAR_BLINN) && !defined(SPECULAR_PHONG) && !defined(SPECULAR_TOON)
|
||||
#define SPECULAR_SCHLICK_GGX
|
||||
#endif
|
||||
|
||||
#if defined(DIFFUSE_BURLEY) || defined(SPECULAR_BLINN) || defined(SPECULAR_SCHLICK_GGX) || defined(LIGHT_USE_CLEARCOAT)
|
||||
vec3 H = normalize(V + L);
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue