diff options
author | Ptolemy <ptolemy@lindenlab.com> | 2022-06-22 11:32:10 -0700 |
---|---|---|
committer | Ptolemy <ptolemy@lindenlab.com> | 2022-06-22 11:32:10 -0700 |
commit | 4d2b2f464be0c1b42462abf31b422e7248d49131 (patch) | |
tree | 2c8aed74cb6c3bc846c404bd86408e962108f00a /indra | |
parent | 27ca7760cc4126c8c45a5c22edafee5d2984a742 (diff) |
SL-17274: Add GBuffer flag for PBR
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llrender/llshadermgr.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/indra/llrender/llshadermgr.cpp b/indra/llrender/llshadermgr.cpp index 4700d351f7..fd1e85c68d 100644 --- a/indra/llrender/llshadermgr.cpp +++ b/indra/llrender/llshadermgr.cpp @@ -790,9 +790,10 @@ 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 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"); + 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 0.25\n"); // bit 0 + extra_code_text[extra_code_count++] = strdup("#define GBUFFER_FLAG_HAS_PBR 0.50\n"); // bit 1 + extra_code_text[extra_code_count++] = strdup("#define GET_GBUFFER_FLAG(flag) (mod(floor(norm.w/flag),2.0)>0.5)\n"); if (defines) { |