diff options
author | Geenz <geenz@geenzo.com> | 2019-03-29 08:11:56 -0700 |
---|---|---|
committer | Geenz <geenz@geenzo.com> | 2019-03-29 08:11:56 -0700 |
commit | 57d88a8a98ef8663b9064b12143beb4068e58f86 (patch) | |
tree | 8b37cf56aa5e6d0882caee2bcd79b22c90f5350b /indra/newview/llvosky.cpp | |
parent | 3fa8b844c39311a2e4e319a8d4f7ab2c848ae140 (diff) |
Gamma correction pass 2:
Make sure lights are in the correct color space.
Bonus: cache the sRGB color in setLightColor on point and spot lights. Frees up a pow and some multiplies on the CPU every frame.
Diffstat (limited to 'indra/newview/llvosky.cpp')
-rw-r--r-- | indra/newview/llvosky.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/indra/newview/llvosky.cpp b/indra/newview/llvosky.cpp index 8bcd875d90..954a590682 100644 --- a/indra/newview/llvosky.cpp +++ b/indra/newview/llvosky.cpp @@ -210,6 +210,9 @@ void LLSkyTex::createGLImage(S32 which) if (LLPipeline::RenderDeferred) { mTexture[which]->setExplicitFormat(GL_SRGB8_ALPHA8, GL_RGBA); } + else { + mTexture[which]->setExplicitFormat(GL_RGBA8, GL_RGBA); + } mTexture[which]->createGLTexture(0, mImageRaw[which], 0, TRUE, LLGLTexture::LOCAL); mTexture[which]->setAddressMode(LLTexUnit::TAM_CLAMP); } |