From 768b7a4d33b64dc3e9d7f7c0c384bb2aa37b458b Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Tue, 9 Nov 2021 17:17:49 +0200 Subject: SL-16330 Clean up vertical sync handling, add to UI --- indra/newview/llviewercontrol.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 76dc9a6790..3e7459ee8a 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -241,6 +241,12 @@ static bool handleAnisotropicChanged(const LLSD& newvalue) return true; } +static bool handleVSyncChanged(const LLSD& newvalue) +{ + gViewerWindow->getWindow()->toggleVSync(newvalue.asBoolean()); + return true; +} + static bool handleVolumeLODChanged(const LLSD& newvalue) { LLVOVolume::sLODFactor = llclamp((F32) newvalue.asReal(), 0.01f, MAX_LOD_FACTOR); @@ -665,6 +671,7 @@ void settings_setup_listeners() gSavedSettings.getControl("RenderAutoMaskAlphaNonDeferred")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2)); gSavedSettings.getControl("RenderObjectBump")->getSignal()->connect(boost::bind(&handleRenderBumpChanged, _2)); gSavedSettings.getControl("RenderMaxVBOSize")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2)); + gSavedSettings.getControl("RenderVSyncEnable")->getSignal()->connect(boost::bind(&handleVSyncChanged, _2)); gSavedSettings.getControl("RenderDeferredNoise")->getSignal()->connect(boost::bind(&handleReleaseGLBufferChanged, _2)); gSavedSettings.getControl("RenderDebugGL")->getSignal()->connect(boost::bind(&handleRenderDebugGLChanged, _2)); gSavedSettings.getControl("RenderDebugPipeline")->getSignal()->connect(boost::bind(&handleRenderDebugPipelineChanged, _2)); -- cgit v1.2.3 From d3b8f823fa48a6f7d15d569b9e554e25c97075f6 Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Wed, 10 Nov 2021 18:44:00 +0200 Subject: SL-16330 mac build fix --- indra/newview/llviewercontrol.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 3e7459ee8a..0e64d7152a 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -243,7 +243,9 @@ static bool handleAnisotropicChanged(const LLSD& newvalue) static bool handleVSyncChanged(const LLSD& newvalue) { +#if LL_WINDOWS gViewerWindow->getWindow()->toggleVSync(newvalue.asBoolean()); +#endif return true; } -- cgit v1.2.3 From 709184e0ffdd9967444c07bd52d479be4d932835 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Tue, 14 Sep 2021 22:43:17 +0300 Subject: SL-15993 Disabling transparent water should not disable advanced lighting --- indra/newview/llviewercontrol.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 0e64d7152a..e5ebbcb9ab 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -187,7 +187,6 @@ static bool handleRenderPerfTestChanged(const LLSD& newvalue) bool handleRenderTransparentWaterChanged(const LLSD& newvalue) { - LLRenderTarget::sUseFBO = newvalue.asBoolean(); if (gPipeline.isInit()) { gPipeline.updateRenderTransparentWater(); -- cgit v1.2.3 From e95b7efd0b4469ce18bce3bc0261ecc9be06ea9c Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Tue, 16 Nov 2021 16:18:01 +0200 Subject: SL-16362 FIXED Viewer crashes if settings.xml file is missing --- indra/newview/llviewercontrol.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index e5ebbcb9ab..693c24634e 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -107,10 +107,14 @@ static bool handleRenderAvatarMouselookChanged(const LLSD& newvalue) static bool handleRenderFarClipChanged(const LLSD& newvalue) { - F32 draw_distance = (F32) newvalue.asReal(); - gAgentCamera.mDrawDistance = draw_distance; - LLWorld::getInstance()->setLandFarClip(draw_distance); - return true; + if (LLStartUp::getStartupState() >= STATE_STARTED) + { + F32 draw_distance = (F32)newvalue.asReal(); + gAgentCamera.mDrawDistance = draw_distance; + LLWorld::getInstance()->setLandFarClip(draw_distance); + return true; + } + return false; } static bool handleTerrainDetailChanged(const LLSD& newvalue) -- cgit v1.2.3 From fdeeb0190eb6fa2d6b39816d14a664f5d38aa4ec Mon Sep 17 00:00:00 2001 From: Mnikolenko ProductEngine Date: Wed, 17 Nov 2021 17:51:50 +0200 Subject: SL-16330 Allow vsync update without restart on mac --- indra/newview/llviewercontrol.cpp | 2 -- 1 file changed, 2 deletions(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 9f76543647..e20c64e48e 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -260,9 +260,7 @@ static bool handleAnisotropicChanged(const LLSD& newvalue) static bool handleVSyncChanged(const LLSD& newvalue) { -#if LL_WINDOWS gViewerWindow->getWindow()->toggleVSync(newvalue.asBoolean()); -#endif return true; } -- cgit v1.2.3 From ca4fb96e1dfb5c372fe6f0951db7e14266db538e Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Wed, 10 Nov 2021 18:44:00 +0200 Subject: SL-16330 mac build fix --- indra/newview/llviewercontrol.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 3e7459ee8a..0e64d7152a 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -243,7 +243,9 @@ static bool handleAnisotropicChanged(const LLSD& newvalue) static bool handleVSyncChanged(const LLSD& newvalue) { +#if LL_WINDOWS gViewerWindow->getWindow()->toggleVSync(newvalue.asBoolean()); +#endif return true; } -- cgit v1.2.3 From 1acd92c30c88a9718385f29a558b77bd20588764 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Tue, 14 Sep 2021 22:43:17 +0300 Subject: SL-15993 Disabling transparent water should not disable advanced lighting --- indra/newview/llviewercontrol.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 0e64d7152a..e5ebbcb9ab 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -187,7 +187,6 @@ static bool handleRenderPerfTestChanged(const LLSD& newvalue) bool handleRenderTransparentWaterChanged(const LLSD& newvalue) { - LLRenderTarget::sUseFBO = newvalue.asBoolean(); if (gPipeline.isInit()) { gPipeline.updateRenderTransparentWater(); -- cgit v1.2.3 From bc9552900339526b241cfd6ee4fb90a498868fd6 Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Tue, 30 Nov 2021 19:01:33 +0200 Subject: SL-16369 Remove Hardware Skinning setting --- indra/newview/llviewercontrol.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 9f76543647..3c6c9c905a 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -659,7 +659,6 @@ void settings_setup_listeners() gSavedSettings.getControl("OctreeAttachmentSizeFactor")->getSignal()->connect(boost::bind(&handleRepartition, _2)); gSavedSettings.getControl("RenderMaxTextureIndex")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _2)); gSavedSettings.getControl("RenderUseTriStrips")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2)); - gSavedSettings.getControl("RenderAvatarVP")->getSignal()->connect(boost::bind(&handleSetShaderChanged, _2)); gSavedSettings.getControl("RenderUIBuffer")->getSignal()->connect(boost::bind(&handleWindowResized, _2)); gSavedSettings.getControl("RenderDepthOfField")->getSignal()->connect(boost::bind(&handleReleaseGLBufferChanged, _2)); gSavedSettings.getControl("RenderFSAASamples")->getSignal()->connect(boost::bind(&handleReleaseGLBufferChanged, _2)); -- cgit v1.2.3 From 68e09edad0d863d57ba06e2842b9399f3ff21618 Mon Sep 17 00:00:00 2001 From: Dave Houlton Date: Mon, 29 Nov 2021 17:07:25 -0700 Subject: SL-16386 remove references to (const true) LLGLSLShader::sNoFixedFunction --- indra/newview/llviewercontrol.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 3c6c9c905a..19b25a01fe 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -388,7 +388,7 @@ static bool handleJoystickChanged(const LLSD& newvalue) static bool handleUseOcclusionChanged(const LLSD& newvalue) { - LLPipeline::sUseOcclusion = (newvalue.asBoolean() && gGLManager.mHasOcclusionQuery && LLGLSLShader::sNoFixedFunction + LLPipeline::sUseOcclusion = (newvalue.asBoolean() && gGLManager.mHasOcclusionQuery && LLFeatureManager::getInstance()->isFeatureAvailable("UseOcclusion") && !gUseWireframe) ? 2 : 0; return true; } -- cgit v1.2.3 From 752bcc16fc57070a06a572eae2fce18fc181136d Mon Sep 17 00:00:00 2001 From: Dave Houlton Date: Thu, 16 Dec 2021 10:20:14 -0700 Subject: DRTVWR-546 remove dead fxn that breaks Mac build --- indra/newview/llviewercontrol.cpp | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index fcacc933e0..41c477f678 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -166,17 +166,6 @@ static bool handleSetShaderChanged(const LLSD& newvalue) return true; } -static bool handleAvatarVPChanged(const LLSD& newvalue) -{ - LLRenderTarget::sUseFBO = newvalue.asBoolean() - && gSavedSettings.getBOOL("RenderObjectBump") - && gSavedSettings.getBOOL("RenderTransparentWater") - && gSavedSettings.getBOOL("RenderDeferred"); - - handleSetShaderChanged(LLSD()); - return true; -} - static bool handleRenderPerfTestChanged(const LLSD& newvalue) { bool status = !newvalue.asBoolean(); -- cgit v1.2.3 From bebdeb430ba72ab1c7eddc2f10d43b36f1992827 Mon Sep 17 00:00:00 2001 From: Dave Houlton Date: Thu, 16 Dec 2021 10:50:49 -0700 Subject: DRTVWR-546 fix dead setting merge error --- indra/newview/llviewercontrol.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 41c477f678..a4f8963dc3 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -467,7 +467,6 @@ static bool handleRenderBumpChanged(const LLSD& newval) { LLRenderTarget::sUseFBO = newval.asBoolean() && gSavedSettings.getBOOL("RenderTransparentWater") - && gSavedSettings.getBOOL("RenderAvatarVP") && gSavedSettings.getBOOL("RenderDeferred"); if (gPipeline.isInit()) { -- cgit v1.2.3 From 0fd7d20949a3f471e7ebb78731612013dfad7b0d Mon Sep 17 00:00:00 2001 From: Dave Houlton Date: Thu, 16 Dec 2021 11:14:14 -0700 Subject: DRTVWR-546 fix sUseFBO merge errors --- indra/newview/llviewercontrol.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'indra/newview/llviewercontrol.cpp') diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index a4f8963dc3..e53f988c6e 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -465,9 +465,7 @@ static bool handleRenderDeferredChanged(const LLSD& newvalue) // static bool handleRenderBumpChanged(const LLSD& newval) { - LLRenderTarget::sUseFBO = newval.asBoolean() - && gSavedSettings.getBOOL("RenderTransparentWater") - && gSavedSettings.getBOOL("RenderDeferred"); + LLRenderTarget::sUseFBO = newval.asBoolean() && gSavedSettings.getBOOL("RenderDeferred"); if (gPipeline.isInit()) { gPipeline.updateRenderBump(); -- cgit v1.2.3