From 6303ef5763393021d35c55a012cacfa7ee8c650e Mon Sep 17 00:00:00 2001 From: "Graham Linden graham@lindenlab.com" Date: Mon, 26 Feb 2018 16:38:50 +0000 Subject: Redo advanced atmo shader integration with SL. --- indra/llrender/llatmosphere.cpp | 3 +++ indra/llrender/llglslshader.cpp | 4 ++++ 2 files changed, 7 insertions(+) (limited to 'indra/llrender') diff --git a/indra/llrender/llatmosphere.cpp b/indra/llrender/llatmosphere.cpp index fb159a3e47..8840f49454 100644 --- a/indra/llrender/llatmosphere.cpp +++ b/indra/llrender/llatmosphere.cpp @@ -167,18 +167,21 @@ LLAtmosphere::LLAtmosphere() m_scattering = new LLGLTexture; m_mie_scattering = new LLGLTexture; + m_transmittance->generateGLTexture(); m_transmittance->setAddressMode(LLTexUnit::eTextureAddressMode::TAM_CLAMP); m_transmittance->setFilteringOption(LLTexUnit::eTextureFilterOptions::TFO_BILINEAR); m_transmittance->setExplicitFormat(GL_RGB16F, GL_RGB, GL_FLOAT); m_transmittance->setTexName(m_textures.transmittance_texture); m_transmittance->setTarget(GL_TEXTURE_2D, LLTexUnit::TT_TEXTURE); + m_scattering->generateGLTexture(); m_scattering->setAddressMode(LLTexUnit::eTextureAddressMode::TAM_CLAMP); m_scattering->setFilteringOption(LLTexUnit::eTextureFilterOptions::TFO_BILINEAR); m_scattering->setExplicitFormat(GL_RGB16F, GL_RGB, GL_FLOAT); m_scattering->setTexName(m_textures.transmittance_texture); m_scattering->setTarget(GL_TEXTURE_3D, LLTexUnit::TT_TEXTURE_3D); + m_mie_scattering->generateGLTexture(); m_mie_scattering->setAddressMode(LLTexUnit::eTextureAddressMode::TAM_CLAMP); m_mie_scattering->setFilteringOption(LLTexUnit::eTextureFilterOptions::TFO_BILINEAR); m_mie_scattering->setExplicitFormat(GL_RGB16F, GL_RGB, GL_FLOAT); diff --git a/indra/llrender/llglslshader.cpp b/indra/llrender/llglslshader.cpp index b09ec53bc0..a5939a6eb9 100644 --- a/indra/llrender/llglslshader.cpp +++ b/indra/llrender/llglslshader.cpp @@ -374,6 +374,8 @@ void LLGLSLShader::unloadInternal() stop_glerror(); } +#pragma optimize("", off) + BOOL LLGLSLShader::createShader(std::vector * attributes, std::vector * uniforms, U32 varying_count, @@ -490,6 +492,8 @@ BOOL LLGLSLShader::createShader(std::vector * attributes, return success; } +#pragma optimize("", on) + BOOL LLGLSLShader::attachObject(std::string object) { if (LLShaderMgr::instance()->mShaderObjects.count(object) > 0) -- cgit v1.2.3