From e1c7688b2c69c3a79b673011abe6d59ce97acdff Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Mon, 26 Nov 2018 18:50:40 +0200 Subject: SL-10101 Remade most frequent setting calls to cached variants --- indra/newview/llappviewer.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 4374caacdf..f1af872fb4 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -5439,7 +5439,8 @@ void LLAppViewer::resumeMainloopTimeout(const std::string& state, F32 secs) { if(secs < 0.0f) { - secs = gSavedSettings.getF32("MainloopTimeoutDefault"); + static LLCachedControl mainloop_timeout(gSavedSettings, "MainloopTimeoutDefault", 60); + secs = mainloop_timeout; } mMainloopTimeout->setTimeout(secs); @@ -5466,7 +5467,8 @@ void LLAppViewer::pingMainloopTimeout(const std::string& state, F32 secs) { if(secs < 0.0f) { - secs = gSavedSettings.getF32("MainloopTimeoutDefault"); + static LLCachedControl mainloop_timeout(gSavedSettings, "MainloopTimeoutDefault", 60); + secs = mainloop_timeout; } mMainloopTimeout->setTimeout(secs); -- cgit v1.2.3 From e2442851c61ad645020d78be8ae0c7c851024758 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Tue, 27 Nov 2018 20:07:41 +0200 Subject: SL-10080 Limit LOD factor to 4 --- indra/newview/llappviewer.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index f1af872fb4..bd45f68a5c 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -568,12 +568,12 @@ static void settings_to_globals() LLVertexBuffer::sUseVAO = gSavedSettings.getBOOL("RenderUseVAO"); LLImageGL::sGlobalUseAnisotropic = gSavedSettings.getBOOL("RenderAnisotropic"); LLImageGL::sCompressTextures = gSavedSettings.getBOOL("RenderCompressTextures"); - LLVOVolume::sLODFactor = gSavedSettings.getF32("RenderVolumeLODFactor"); + LLVOVolume::sLODFactor = llmin(gSavedSettings.getF32("RenderVolumeLODFactor"), MAX_LOD_FACTOR); LLVOVolume::sDistanceFactor = 1.f-LLVOVolume::sLODFactor * 0.1f; LLVolumeImplFlexible::sUpdateFactor = gSavedSettings.getF32("RenderFlexTimeFactor"); LLVOTree::sTreeFactor = gSavedSettings.getF32("RenderTreeLODFactor"); - LLVOAvatar::sLODFactor = gSavedSettings.getF32("RenderAvatarLODFactor"); - LLVOAvatar::sPhysicsLODFactor = gSavedSettings.getF32("RenderAvatarPhysicsLODFactor"); + LLVOAvatar::sLODFactor = llmin(gSavedSettings.getF32("RenderAvatarLODFactor"), MAX_LOD_FACTOR); + LLVOAvatar::sPhysicsLODFactor = llmin(gSavedSettings.getF32("RenderAvatarPhysicsLODFactor"), MAX_LOD_FACTOR); LLVOAvatar::updateImpostorRendering(gSavedSettings.getU32("RenderAvatarMaxNonImpostors")); LLVOAvatar::sVisibleInFirstPerson = gSavedSettings.getBOOL("FirstPersonAvatarVisible"); // clamp auto-open time to some minimum usable value -- cgit v1.2.3 From c94e981f40652920a7fb5234a65369bf58d41865 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Mon, 3 Dec 2018 17:30:35 +0200 Subject: SL-10080 clamp instead of llmax --- indra/newview/llappviewer.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index bd45f68a5c..7c79cc7ddf 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -568,12 +568,12 @@ static void settings_to_globals() LLVertexBuffer::sUseVAO = gSavedSettings.getBOOL("RenderUseVAO"); LLImageGL::sGlobalUseAnisotropic = gSavedSettings.getBOOL("RenderAnisotropic"); LLImageGL::sCompressTextures = gSavedSettings.getBOOL("RenderCompressTextures"); - LLVOVolume::sLODFactor = llmin(gSavedSettings.getF32("RenderVolumeLODFactor"), MAX_LOD_FACTOR); + LLVOVolume::sLODFactor = llclamp(gSavedSettings.getF32("RenderVolumeLODFactor"), 0.01f, MAX_LOD_FACTOR); LLVOVolume::sDistanceFactor = 1.f-LLVOVolume::sLODFactor * 0.1f; LLVolumeImplFlexible::sUpdateFactor = gSavedSettings.getF32("RenderFlexTimeFactor"); LLVOTree::sTreeFactor = gSavedSettings.getF32("RenderTreeLODFactor"); - LLVOAvatar::sLODFactor = llmin(gSavedSettings.getF32("RenderAvatarLODFactor"), MAX_LOD_FACTOR); - LLVOAvatar::sPhysicsLODFactor = llmin(gSavedSettings.getF32("RenderAvatarPhysicsLODFactor"), MAX_LOD_FACTOR); + LLVOAvatar::sLODFactor = llclamp(gSavedSettings.getF32("RenderAvatarLODFactor"), 0.f, MAX_AVATAR_LOD_FACTOR); + LLVOAvatar::sPhysicsLODFactor = llclamp(gSavedSettings.getF32("RenderAvatarPhysicsLODFactor"), 0.f, MAX_AVATAR_LOD_FACTOR); LLVOAvatar::updateImpostorRendering(gSavedSettings.getU32("RenderAvatarMaxNonImpostors")); LLVOAvatar::sVisibleInFirstPerson = gSavedSettings.getBOOL("FirstPersonAvatarVisible"); // clamp auto-open time to some minimum usable value -- cgit v1.2.3 From 26fae750ba753f32f58bd56d297f2d98c5759e50 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Mon, 14 Jan 2019 22:04:44 +0200 Subject: SL-10291 Replace apr_mutex with standard C++11 functionality --- indra/newview/llappviewer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 7c79cc7ddf..f8fa06b527 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -2148,7 +2148,7 @@ bool LLAppViewer::initThreads() if (LLTrace::BlockTimer::sLog || LLTrace::BlockTimer::sMetricLog) { - LLTrace::BlockTimer::setLogLock(new LLMutex(NULL)); + LLTrace::BlockTimer::setLogLock(new LLMutex()); mFastTimerLogThread = new LLFastTimerLogThread(LLTrace::BlockTimer::sLogName); mFastTimerLogThread->start(); } -- cgit v1.2.3 From 4e73121719511e584ab615dc9c5f672704d0cdb7 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Mon, 4 Mar 2019 20:24:00 +0000 Subject: Don't create updater when running under debugger. --- indra/newview/llappviewer.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index b7e2f17c46..c308663a62 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -1160,7 +1160,10 @@ bool LLAppViewer::init() updater.args.add(stringize(gSavedSettings.getU32("ForceAddressSize"))); // Run the updater. An exception from launching the updater should bother us. - LLLeap::create(updater, true); + if (!beingDebugged()) + { + LLLeap::create(updater, true); + } // Iterate over --leap command-line options. But this is a bit tricky: if // there's only one, it won't be an array at all. -- cgit v1.2.3 From 5966831b0cc4f5abae63369d56d83d7cafb7810b Mon Sep 17 00:00:00 2001 From: maxim_productengine Date: Thu, 4 Apr 2019 13:20:36 +0300 Subject: SL-10881 Add HiDPI status to Help - About Second Life report --- indra/newview/llappviewer.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 577082f01f..7476ab1c5f 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -3173,6 +3173,10 @@ LLSD LLAppViewer::getViewerInfo() const substitution["datetime"] = (S32)(gVFS ? gVFS->creationTime() : 0); info["VFS_TIME"] = LLTrans::getString("AboutTime", substitution); +#if LL_DARWIN + info["HIDPI"] = gHiDPISupport; +#endif + // Libraries info["J2C_VERSION"] = LLImageJ2C::getEngineInfo(); @@ -3315,6 +3319,9 @@ std::string LLAppViewer::getViewerInfoString(bool default_string) const } support << "\n" << LLTrans::getString("AboutOGL", args, default_string); support << "\n\n" << LLTrans::getString("AboutSettings", args, default_string); +#if LL_DARWIN + support << "\n" << LLTrans::getString("AboutOSXHiDPI", args, default_string); +#endif support << "\n\n" << LLTrans::getString("AboutLibs", args, default_string); if (info.has("COMPILER")) { -- cgit v1.2.3 From f7f939ecf2ed1a0a5970b91aa0227fa0cf012a72 Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Wed, 10 Apr 2019 16:17:55 +0300 Subject: Don't crash Test Viewer due to missing version checker --- indra/newview/llappviewer.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 7476ab1c5f..5592cd3e59 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -1167,11 +1167,18 @@ bool LLAppViewer::init() // ForceAddressSize updater.args.add(stringize(gSavedSettings.getU32("ForceAddressSize"))); - // Run the updater. An exception from launching the updater should bother us. - if (!beingDebugged()) +#if LL_WINDOWS && !LL_RELEASE_FOR_DOWNLOAD && !LL_SEND_CRASH_REPORTS + // This is neither a release package, nor crash-reporting enabled test build + // try to run version updater, but don't bother if it fails (file might be missing) + LLLeap *leap_p = LLLeap::create(updater, false); + if (!leap_p) { - LLLeap::create(updater, true); + LL_WARNS("LLLeap") << "Failed to run LLLeap" << LL_ENDL; } +#else + // Run the updater. An exception from launching the updater should bother us. + LLLeap::create(updater, true); +#endif // Iterate over --leap command-line options. But this is a bit tricky: if // there's only one, it won't be an array at all. -- cgit v1.2.3 From c9cc8f6ddedefc681ac2fe08034c57c87c1d745c Mon Sep 17 00:00:00 2001 From: andreykproductengine Date: Wed, 10 Apr 2019 21:31:01 +0300 Subject: Don't crash Test Viewer due to missing version checker --- indra/newview/llappviewer.cpp | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'indra/newview/llappviewer.cpp') diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 5592cd3e59..6202a382b1 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -1167,14 +1167,10 @@ bool LLAppViewer::init() // ForceAddressSize updater.args.add(stringize(gSavedSettings.getU32("ForceAddressSize"))); -#if LL_WINDOWS && !LL_RELEASE_FOR_DOWNLOAD && !LL_SEND_CRASH_REPORTS - // This is neither a release package, nor crash-reporting enabled test build - // try to run version updater, but don't bother if it fails (file might be missing) - LLLeap *leap_p = LLLeap::create(updater, false); - if (!leap_p) - { - LL_WARNS("LLLeap") << "Failed to run LLLeap" << LL_ENDL; - } +#if !LL_RELEASE_FOR_DOWNLOAD && !LL_SEND_CRASH_REPORTS + // This is neither a release package, nor crash-reporting enabled test build + // Note: pointless to launch on Windows - it shouldn't expect secondlife-bin.exe + LL_WARNS("LLLeap") << "Launching without version checker" << LL_ENDL; #else // Run the updater. An exception from launching the updater should bother us. LLLeap::create(updater, true); -- cgit v1.2.3