summaryrefslogtreecommitdiff
path: root/indra/newview/lllegacyatmospherics.cpp
diff options
context:
space:
mode:
authorEuclid Linden <euclid@lindenlab.com>2021-12-01 15:59:02 +0000
committerEuclid Linden <euclid@lindenlab.com>2021-12-01 15:59:02 +0000
commit3f82f7ce3d4fb51407f366b2ad2f15d990de40b2 (patch)
tree45be0f3213f0e095d9a7929c693f4671c8b58e08 /indra/newview/lllegacyatmospherics.cpp
parent01317a2faded53c79db7e0814426f1d8b2fd12fc (diff)
parentabd7d80048529fd971e1b65ea3afe0f7e78bd356 (diff)
Merged in euclid-pre-16386 (pull request #793)
Purge LLGLSLShader::sNoFixedFunction, and all that flows from it. No functional changes. Approved-by: Michael Pohoreski Approved-by: Dave Parks
Diffstat (limited to 'indra/newview/lllegacyatmospherics.cpp')
-rw-r--r--indra/newview/lllegacyatmospherics.cpp31
1 files changed, 0 insertions, 31 deletions
diff --git a/indra/newview/lllegacyatmospherics.cpp b/indra/newview/lllegacyatmospherics.cpp
index 238e9fe0e1..1364067949 100644
--- a/indra/newview/lllegacyatmospherics.cpp
+++ b/indra/newview/lllegacyatmospherics.cpp
@@ -383,12 +383,6 @@ void LLAtmospherics::updateFog(const F32 distance, const LLVector3& tosun_in)
if (!gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_FOG))
{
- if (!LLGLSLShader::sNoFixedFunction)
- {
- glFogf(GL_FOG_DENSITY, 0);
- glFogfv(GL_FOG_COLOR, (F32 *) &LLColor4::white.mV);
- glFogf(GL_FOG_END, 1000000.f);
- }
return;
}
@@ -484,10 +478,6 @@ void LLAtmospherics::updateFog(const F32 distance, const LLVector3& tosun_in)
if (camera_height > water_height)
{
LLColor4 fog(render_fog_color);
- if (!LLGLSLShader::sNoFixedFunction)
- {
- glFogfv(GL_FOG_COLOR, fog.mV);
- }
mGLFogCol = fog;
if (hide_clip_plane)
@@ -495,19 +485,11 @@ void LLAtmospherics::updateFog(const F32 distance, const LLVector3& tosun_in)
// For now, set the density to extend to the cull distance.
const F32 f_log = 2.14596602628934723963618357029f; // sqrt(fabs(log(0.01f)))
fog_density = f_log/fog_distance;
- if (!LLGLSLShader::sNoFixedFunction)
- {
- glFogi(GL_FOG_MODE, GL_EXP2);
- }
}
else
{
const F32 f_log = 4.6051701859880913680359829093687f; // fabs(log(0.01f))
fog_density = (f_log)/fog_distance;
- if (!LLGLSLShader::sNoFixedFunction)
- {
- glFogi(GL_FOG_MODE, GL_EXP);
- }
}
}
else
@@ -533,12 +515,6 @@ void LLAtmospherics::updateFog(const F32 distance, const LLVector3& tosun_in)
// set the density based on what the shaders use
fog_density = water_fog_density * gSavedSettings.getF32("WaterGLFogDensityScale");
-
- if (!LLGLSLShader::sNoFixedFunction)
- {
- glFogfv(GL_FOG_COLOR, (F32 *) &fogCol.mV);
- glFogi(GL_FOG_MODE, GL_EXP2);
- }
}
mFogColor = sky_fog_color;
@@ -546,13 +522,6 @@ void LLAtmospherics::updateFog(const F32 distance, const LLVector3& tosun_in)
LLDrawPoolWater::sWaterFogEnd = fog_distance*2.2f;
- if (!LLGLSLShader::sNoFixedFunction)
- {
- LLGLSFog gls_fog;
- glFogf(GL_FOG_END, fog_distance*2.2f);
- glFogf(GL_FOG_DENSITY, fog_density);
- glHint(GL_FOG_HINT, GL_NICEST);
- }
stop_glerror();
}