From 27ca7760cc4126c8c45a5c22edafee5d2984a742 Mon Sep 17 00:00:00 2001 From: Ptolemy Date: Tue, 21 Jun 2022 22:23:38 -0700 Subject: SL-17274: Remove hard-coded magic number checking if G-Buffer flag is set --- indra/llrender/llshadermgr.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'indra/llrender') 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) { -- cgit v1.2.3