summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1/interface
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2022-10-19 14:41:17 -0500
committerDave Parks <davep@lindenlab.com>2022-10-19 14:41:17 -0500
commitde4c018499ddaebbe466fb5a8938554a2d4a3b19 (patch)
treec2571311bb27190bc2ef9ff03c071169748ef7a2 /indra/newview/app_settings/shaders/class1/interface
parentd0c2c862efe2ce684b48092465cc753b3ab64da9 (diff)
SL-18105 Hook up render pipe directly to LLTextureEntry::mGLTFMaterial and add LLViewerFetchedTextures to LLFetchedGLTFMaterial. Lower reflection probe resolution to 128x128 per side.
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/interface')
-rw-r--r--indra/newview/app_settings/shaders/class1/interface/irradianceGenF.glsl2
-rw-r--r--indra/newview/app_settings/shaders/class1/interface/radianceGenF.glsl4
2 files changed, 3 insertions, 3 deletions
diff --git a/indra/newview/app_settings/shaders/class1/interface/irradianceGenF.glsl b/indra/newview/app_settings/shaders/class1/interface/irradianceGenF.glsl
index b633813819..feaf562686 100644
--- a/indra/newview/app_settings/shaders/class1/interface/irradianceGenF.glsl
+++ b/indra/newview/app_settings/shaders/class1/interface/irradianceGenF.glsl
@@ -196,7 +196,7 @@ vec4 filterColor(vec3 N)
// apply the bias to the lod
lod += u_lodBias;
- lod = clamp(lod, 0, 7);
+ lod = clamp(lod, 0, 6);
// sample lambertian at a lower resolution to avoid fireflies
vec4 lambertian = textureLod(reflectionProbes, vec4(H, sourceIdx), lod);
diff --git a/indra/newview/app_settings/shaders/class1/interface/radianceGenF.glsl b/indra/newview/app_settings/shaders/class1/interface/radianceGenF.glsl
index f4879b52de..32f157e9d2 100644
--- a/indra/newview/app_settings/shaders/class1/interface/radianceGenF.glsl
+++ b/indra/newview/app_settings/shaders/class1/interface/radianceGenF.glsl
@@ -127,7 +127,7 @@ vec4 prefilterEnvMap(vec3 R)
float envMapDim = 256.0;
int numSamples = 4;
- float numMips = 7.0;
+ float numMips = 6.0;
float roughness = mipLevel/numMips;
@@ -151,7 +151,7 @@ vec4 prefilterEnvMap(vec3 R)
// Solid angle of 1 pixel across all cube faces
float omegaP = 4.0 * PI / (6.0 * envMapDim * envMapDim);
// Biased (+1.0) mip level for better result
- float mip = roughness == 0.0 ? 0.0 : clamp(0.5 * log2(omegaS / omegaP) + 1.0, 0.0f, 7.f);
+ float mip = roughness == 0.0 ? 0.0 : clamp(0.5 * log2(omegaS / omegaP) + 1.0, 0.0f, numMips);
//float mip = clamp(0.5 * log2(omegaS / omegaP) + 1.0, 0.0f, 7.f);
color += textureLod(reflectionProbes, vec4(L,sourceIdx), mip) * dotNL;
totalWeight += dotNL;