summaryrefslogtreecommitdiff
path: root/indra/llrender
diff options
context:
space:
mode:
authorPtolemy <ptolemy@lindenlab.com>2022-06-21 22:23:38 -0700
committerPtolemy <ptolemy@lindenlab.com>2022-06-21 22:23:38 -0700
commit27ca7760cc4126c8c45a5c22edafee5d2984a742 (patch)
tree1e954a9b758209c1f2e604872e842d808d546262 /indra/llrender
parent77b96114c30232c1d3f3b548bf982f89f11d09da (diff)
SL-17274: Remove hard-coded magic number checking if G-Buffer flag is set
Diffstat (limited to 'indra/llrender')
-rw-r--r--indra/llrender/llshadermgr.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/indra/llrender/llshadermgr.cpp b/indra/llrender/llshadermgr.cpp
index f1996b65e9..4700d351f7 100644
--- a/indra/llrender/llshadermgr.cpp
+++ b/indra/llrender/llshadermgr.cpp
@@ -790,8 +790,9 @@ GLhandleARB LLShaderMgr::loadShaderFile(const std::string& filename, S32 & shade
// Use alpha float to store bit flags
// See: C++: addDeferredAttachment(), shader: frag_data[2]
- extra_code_text[extra_code_count++] = strdup("#define GBUFFER_FLAG_SKIP_ATMOS 1.0\n"); // atmo kill
- extra_code_text[extra_code_count++] = strdup("#define GBUFFER_FLAG_HAS_ATMOS 0.0\n");
+ extra_code_text[extra_code_count++] = strdup("#define GBUFFER_FLAG_SKIP_ATMOS 0.0\n"); // atmo kill
+ extra_code_text[extra_code_count++] = strdup("#define GBUFFER_FLAG_HAS_ATMOS 1.0\n");
+ extra_code_text[extra_code_count++] = strdup("#define GET_GBUFFER_FLAG(flag) (norm.w>0.5)\n");
if (defines)
{