mirror of
https://github.com/X0nk/Bliss-Shader.git
synced 2025-06-20 07:57:55 +08:00
better AO strength control
This commit is contained in:
parent
c13fdfa29d
commit
a3090da0d6
@ -588,7 +588,7 @@ void ApplySSRT(inout vec3 lighting, vec3 normal,vec2 noise,vec3 fragpos, vec2 li
|
||||
#ifdef SKY_CONTRIBUTION_IN_SSRT
|
||||
skycontribution = (skyCloudsFromTex(rayDir, colortex4).rgb / 15.0) * skyLM + torchlight;
|
||||
#else
|
||||
skycontribution = (skylightcolor * skyLM) * max(rayDir.y,1.0 - AO_Strength) + torchlight;
|
||||
skycontribution = (skylightcolor * skyLM) * max(rayDir.y * min(AO_Strength,1.0), 0.05) + torchlight;
|
||||
#endif
|
||||
|
||||
if (rayHit.z < 1.){
|
||||
@ -612,6 +612,11 @@ void ApplySSRT(inout vec3 lighting, vec3 normal,vec2 noise,vec3 fragpos, vec2 li
|
||||
radiance += skycontribution;
|
||||
}
|
||||
}
|
||||
|
||||
// #ifdef SKY_CONTRIBUTION_IN_SSRT
|
||||
occlusion *= AO_Strength;
|
||||
// #endif
|
||||
|
||||
lighting = max(radiance - occlusion,0.0)/nrays;
|
||||
}
|
||||
|
||||
|
@ -90,7 +90,7 @@
|
||||
#define indirect_effect 1 // [0 1 2 3 4]
|
||||
|
||||
#define AO_in_sunlight
|
||||
#define AO_Strength 0.9 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0]
|
||||
#define AO_Strength 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0]
|
||||
|
||||
// #define SKY_CONTRIBUTION_IN_SSRT
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user