summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class3
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2023-01-30 18:56:19 -0600
committerDave Parks <davep@lindenlab.com>2023-01-30 18:56:19 -0600
commit10b8dcc497599042655dcc4037c9ae98d494bd6f (patch)
tree7a3cfb43aad02f032d82d3d2fcbc52ecd0feaac0 /indra/newview/app_settings/shaders/class3
parent3ef31cb9b28f7b026e109eab69d383dddc922850 (diff)
SL-19015 Bump probe resolution back to 256 by default (drop to 128 if vram < 2GB), remove irradiance map feedback loop (one bounce, but but more stable and allows for much brighter first bounce), make sky contribution to irradiance not tint the world blue. Make irradiance that appears in radiance maps match world irradiance.
Diffstat (limited to 'indra/newview/app_settings/shaders/class3')
-rw-r--r--indra/newview/app_settings/shaders/class3/deferred/reflectionProbeF.glsl7
1 files changed, 4 insertions, 3 deletions
diff --git a/indra/newview/app_settings/shaders/class3/deferred/reflectionProbeF.glsl b/indra/newview/app_settings/shaders/class3/deferred/reflectionProbeF.glsl
index 9793ab13de..bb3be7260b 100644
--- a/indra/newview/app_settings/shaders/class3/deferred/reflectionProbeF.glsl
+++ b/indra/newview/app_settings/shaders/class3/deferred/reflectionProbeF.glsl
@@ -36,6 +36,7 @@ uniform samplerCubeArray reflectionProbes;
uniform samplerCubeArray irradianceProbes;
uniform sampler2D sceneMap;
uniform int cube_snapshot;
+uniform float max_probe_lod;
layout (std140) uniform ReflectionProbes
{
@@ -623,7 +624,7 @@ vec3 sampleProbeAmbient(vec3 pos, vec3 dir)
{
col *= 1.0/wsum;
}
-
+
return col;
}
@@ -631,7 +632,7 @@ void sampleReflectionProbes(inout vec3 ambenv, inout vec3 glossenv,
vec2 tc, vec3 pos, vec3 norm, float glossiness, bool errorCorrect)
{
// TODO - don't hard code lods
- float reflection_lods = 6;
+ float reflection_lods = max_probe_lod;
preProbeSample(pos);
vec3 refnormpersp = reflect(pos.xyz, norm.xyz);
@@ -705,7 +706,7 @@ void sampleReflectionProbesLegacy(inout vec3 ambenv, inout vec3 glossenv, inout
vec2 tc, vec3 pos, vec3 norm, float glossiness, float envIntensity)
{
// TODO - don't hard code lods
- float reflection_lods = 7;
+ float reflection_lods = max_probe_lod;
preProbeSample(pos);
vec3 refnormpersp = reflect(pos.xyz, norm.xyz);