diff options
| author | Rye <rye@alchemyviewer.org> | 2025-11-27 07:52:56 -0500 |
|---|---|---|
| committer | Andrey Kleshchev <117672381+akleshchev@users.noreply.github.com> | 2026-01-06 18:34:34 +0200 |
| commit | b9727dd84124756adacfbce73b5a916a2c0dd891 (patch) | |
| tree | 33c732b4735de4989733b2acc4cefff53a70d3d8 /indra/newview/pipeline.cpp | |
| parent | cba36bc1f49990a802892278ca98478edb31eda9 (diff) | |
Migrate sky/cloud rendering to fragment shader and introduce high precision post process option
Signed-off-by: Rye <rye@alchemyviewer.org>
Diffstat (limited to 'indra/newview/pipeline.cpp')
| -rw-r--r-- | indra/newview/pipeline.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 259ea0c84f..4316b850e3 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -820,9 +820,8 @@ LLPipeline::eFBOStatus LLPipeline::doAllocateScreenBuffer(U32 resX, U32 resY) bool LLPipeline::allocateScreenBufferInternal(U32 resX, U32 resY) { LL_PROFILE_ZONE_SCOPED_CATEGORY_DISPLAY; - - static LLCachedControl<bool> has_hdr(gSavedSettings, "RenderHDREnabled", true); - bool hdr = gGLManager.mGLVersion > 4.05f && has_hdr(); + bool has_hdr = gSavedSettings.getBOOL("RenderHDREnabled"); + bool hdr = gGLManager.mGLVersion > 4.05f && has_hdr; if (mRT == &mMainRT) { // hacky -- allocate auxillary buffer @@ -888,6 +887,8 @@ bool LLPipeline::allocateScreenBufferInternal(U32 resX, U32 resY) if (!gCubeSnapshot) // hack to not re-allocate various targets for cube snapshots { + U32 post_color_fmt = gSavedSettings.getBOOL("RenderHighPrecisionPostProcess") ? GL_RGBA16F : GL_RGBA; + if (RenderUIBuffer) { if (!mUIScreen.allocate(resX, resY, GL_RGBA)) @@ -898,10 +899,10 @@ bool LLPipeline::allocateScreenBufferInternal(U32 resX, U32 resY) if (RenderFSAAType > 0) { - if (!mFXAAMap.allocate(resX, resY, GL_RGBA)) return false; + if (!mFXAAMap.allocate(resX, resY, post_color_fmt)) return false; if (RenderFSAAType == 2) { - if (!mSMAABlendBuffer.allocate(resX, resY, GL_RGBA, false)) return false; + if (!mSMAABlendBuffer.allocate(resX, resY, post_color_fmt, false)) return false; } } else @@ -922,8 +923,8 @@ bool LLPipeline::allocateScreenBufferInternal(U32 resX, U32 resY) mSceneMap.release(); } - mPostPingMap.allocate(resX, resY, GL_RGBA); - mPostPongMap.allocate(resX, resY, GL_RGBA); + mPostPingMap.allocate(resX, resY, post_color_fmt); + mPostPongMap.allocate(resX, resY, post_color_fmt); // The water exclusion mask needs its own depth buffer so we can take care of the problem of multiple water planes. // Should we ever make water not just a plane, it also aids with that as well as the water planes will be rendered into the mask. |
