From f57864fbd5fcf287fbdb788fa6a0dc13b92253b3 Mon Sep 17 00:00:00 2001 From: Beq Date: Fri, 8 Nov 2024 20:59:47 +0000 Subject: [PATCH 01/14] Slight mod to Whitelist reminder as per discussion - remove the "ignore" option - make it first run after install only (pretty much the same behaviour - less scope for complaints.) --- indra/newview/app_settings/settings.xml | 11 +++++++++++ indra/newview/llstartup.cpp | 9 +++++++-- indra/newview/skins/default/xui/en/notifications.xml | 4 ---- 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index b63da471a3..ca5cbb114f 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -25920,5 +25920,16 @@ Change of this parameter will affect the layout of buttons in notification toast Value 1 + FSShowWhitelistReminder + + Comment + Show the whitelist reminder on first install. + Persist + 1 + Type + Boolean + Value + 1 + diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index c81f62ff8d..a0202677c1 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -3336,8 +3336,13 @@ void login_show() //LLPanelLogin::show( gViewerWindow->getWindowRectScaled(), login_callback, NULL ); FSPanelLogin::show( gViewerWindow->getWindowRectScaled(), login_callback, NULL ); // [FS Login Panel] - - LLNotificationsUtil::add("WhitelistReminder"); // Whitelist reminder + // Whitelist reminder + if( gSavedSettings.getBOOL("FSShowWhitelistReminder") ) + { + LLNotificationsUtil::add("WhitelistReminder"); + gSavedSettings.setBOOL("FSShowWhitelistReminder", false); + } + // } // Callback for when login screen is closed. Option 0 = connect, option 1 = quit. diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml index dda61c9ef3..eb52b744b9 100644 --- a/indra/newview/skins/default/xui/en/notifications.xml +++ b/indra/newview/skins/default/xui/en/notifications.xml @@ -14640,10 +14640,6 @@ Some antivirus programs may mistakenly block parts of [APP_NAME], slowing down i For detailed instructions on how to whitelist [APP_NAME] - including a list of files and folders to exclude - please visit our guide: https://wiki.firestormviewer.org/antivirus_whitelisting - From cfa296bcf80c44e8ed88e75fc43dc59273af2a5b Mon Sep 17 00:00:00 2001 From: PanteraPolnocy Date: Fri, 8 Nov 2024 23:18:44 +0100 Subject: [PATCH 02/14] Propagate the change to all translations --- indra/newview/skins/default/xui/de/notifications.xml | 1 - indra/newview/skins/default/xui/it/notifications.xml | 1 - indra/newview/skins/default/xui/pl/notifications.xml | 1 - indra/newview/skins/default/xui/ru/notifications.xml | 1 - 4 files changed, 4 deletions(-) diff --git a/indra/newview/skins/default/xui/de/notifications.xml b/indra/newview/skins/default/xui/de/notifications.xml index a08305b3fa..4b54fea90a 100644 --- a/indra/newview/skins/default/xui/de/notifications.xml +++ b/indra/newview/skins/default/xui/de/notifications.xml @@ -5858,6 +5858,5 @@ Einige Antivirus-Programme können fälschlicherweise Teile von [APP_NAME] block Detaillierte Instruktionen zum whitelisten von [APP_NAME] - inklusive einer Liste von Dateien und Verzeichnissen - finden Sie in unserem Ratgeber: https://wiki.firestormviewer.org/antivirus_whitelisting - diff --git a/indra/newview/skins/default/xui/it/notifications.xml b/indra/newview/skins/default/xui/it/notifications.xml index 632343a5a0..4e0cac2b26 100644 --- a/indra/newview/skins/default/xui/it/notifications.xml +++ b/indra/newview/skins/default/xui/it/notifications.xml @@ -5371,6 +5371,5 @@ Alcuni programmi antivirus potrebbero bloccare erroneamente parti di [APP_NAME], Per istruzioni dettagliate su come autorizzare [APP_NAME], che includono l'elenco di file e cartelle da escludere, consulta la nostra guida: https://wiki.firestormviewer.org/antivirus_whitelisting - diff --git a/indra/newview/skins/default/xui/pl/notifications.xml b/indra/newview/skins/default/xui/pl/notifications.xml index d1b23e9e24..f3f618857e 100644 --- a/indra/newview/skins/default/xui/pl/notifications.xml +++ b/indra/newview/skins/default/xui/pl/notifications.xml @@ -5478,6 +5478,5 @@ Niektóre programy antywirusowe mogą błędnie blokować części [APP_NAME]a, Aby uzyskać szczegółowe instrukcje dotyczące umieszczania [APP_NAME]a na białej liście - w tym listę plików i folderów do wykluczenia - zapoznaj się z naszym przewodnikiem: https://wiki.firestormviewer.org/antivirus_whitelisting - diff --git a/indra/newview/skins/default/xui/ru/notifications.xml b/indra/newview/skins/default/xui/ru/notifications.xml index 5df91a8ecc..5e2c3cc3ea 100644 --- a/indra/newview/skins/default/xui/ru/notifications.xml +++ b/indra/newview/skins/default/xui/ru/notifications.xml @@ -5632,7 +5632,6 @@ https://wiki.firestormviewer.org/fs_voice Для получения подробных инструкций о том, как внести [APP_NAME] в белый список, включая список файлов и папок, которые необходимо исключить, ознакомьтесь с нашим руководством: https://wiki.firestormviewer.org/antivirus_whitelisting - From 38593989827c72545bb11c3d4188e0e3e81b64c9 Mon Sep 17 00:00:00 2001 From: Beq Date: Fri, 8 Nov 2024 22:28:40 +0000 Subject: [PATCH 03/14] Enable FPS limit by default at 60FPS Silence of the Fans.... --- indra/newview/app_settings/settings.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index ca5cbb114f..c2bb267b67 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -2253,7 +2253,7 @@ Type U32 Value - 120 + 60 BackgroundYieldTime @@ -24074,7 +24074,7 @@ Change of this parameter will affect the layout of buttons in notification toast Type Boolean Value - 0 + 1 FSSoundCacheLocation From 49cd03d5509ececfd80395431a14cbba9273fbca Mon Sep 17 00:00:00 2001 From: Beq Date: Fri, 8 Nov 2024 22:33:08 +0000 Subject: [PATCH 04/14] Add colour to the FPS Text, relocate vsync next to fps limit if there are no limits on FPS it will remain white. if vsync or fps limit are used and the fps is below the lower of the two limits then it will be coloured yellow, if we are at or above a limit then it will be green. Clicking the fps text opens the preferences panel with limit framerate highlighted. --- indra/newview/fsfloaterperformance.cpp | 2 +- indra/newview/llstatusbar.cpp | 62 ++++++++++++++++- .../xui/en/panel_preferences_graphics1.xml | 68 +++++++++++-------- .../skins/default/xui/en/panel_status_bar.xml | 2 +- 4 files changed, 104 insertions(+), 30 deletions(-) diff --git a/indra/newview/fsfloaterperformance.cpp b/indra/newview/fsfloaterperformance.cpp index 7576ff5eb9..81279fc469 100644 --- a/indra/newview/fsfloaterperformance.cpp +++ b/indra/newview/fsfloaterperformance.cpp @@ -315,7 +315,7 @@ void FSFloaterPerformance::draw() args["FPSCAP"] = llformat("%02u", (U32)fpsCap); args["FPSTARGET"] = llformat("%02u", (U32)targetFPS); S32 refresh_rate = gViewerWindow->getWindow()->getRefreshRate(); - args["VSYNCFREQ"] = llformat("%02d", (U32)refresh_rate); + args["VSYNCFREQ"] = llformat("%03d", (U32)refresh_rate); auto textbox = getChild("fps_warning"); // Note: the ordering of these is important. // 1) background_yield should override others diff --git a/indra/newview/llstatusbar.cpp b/indra/newview/llstatusbar.cpp index 5284d40d86..4b07a763f4 100644 --- a/indra/newview/llstatusbar.cpp +++ b/indra/newview/llstatusbar.cpp @@ -63,10 +63,12 @@ #include "llresmgr.h" #include "llworld.h" #include "llstatgraph.h" +#include "llurlaction.h" #include "llviewermedia.h" #include "llviewermenu.h" // for gMenuBarView #include "llviewerparcelmgr.h" #include "llviewerthrottle.h" +#include "llwindow.h" #include "lluictrlfactory.h" #include "lltoolmgr.h" @@ -304,6 +306,9 @@ bool LLStatusBar::postBuild() mBoxBalance = getChild("balance"); mBoxBalance->setClickedCallback( &LLStatusBar::onClickBalance, this ); + // show fpslimit reached in FPS status bar + getChild("FPSText")->setClickedCallback( std::bind(&LLUrlAction::executeSLURL, "secondlife:///app/openfloater/preferences?search=limit%20framerate", true)); + mIconPresetsCamera = getChild( "presets_icon_camera" ); //mIconPresetsCamera->setMouseEnterCallback(boost::bind(&LLStatusBar::mIconPresetsCamera, this)); if (gSavedSettings.getBOOL("FSStatusBarMenuButtonPopupOnRollover")) @@ -483,7 +488,10 @@ bool LLStatusBar::postBuild() mBalancePanel = getChild("balance_bg"); mTimeMediaPanel = getChild("time_and_media_bg"); + // Make FPS a clickable button with contextual colour mFPSText = getChild("FPSText"); + // mFPSText = getChild("FPSText"); + // mVolumeIconsWidth = mBtnVolume->getRect().mRight - mStreamToggle->getRect().mLeft; initParcelIcons(); @@ -598,8 +606,60 @@ void LLStatusBar::refresh() static LLCachedControl fsStatusBarShowFPS(gSavedSettings, "FSStatusBarShowFPS"); if (fsStatusBarShowFPS && mFPSUpdateTimer.getElapsedTimeF32() > 1.f) { + static LLCachedControl max_fps(gSavedSettings, "FramePerSecondLimit"); + static LLCachedControl limit_fps_enabled(gSavedSettings, "FSLimitFramerate"); + static LLCachedControl vsync_enabled(gSavedSettings, "RenderVSyncEnable"); + + const auto FPS_below_limit_color = LLUIColorTable::instance().getColor( "Yellow" ); + const auto FPS_limit_reached_color = LLUIColorTable::instance().getColor( "Green" ); + const auto vsync_limit_reached_color = LLUIColorTable::instance().getColor( "Green" ); + const auto FPS_uncapped_color = LLUIColorTable::instance().getColor( "White" ); + const auto FPS_unfocussed_color = LLUIColorTable::instance().getColor( "Gray" ); mFPSUpdateTimer.reset(); - mFPSText->setText(llformat("%.1f", LLTrace::get_frame_recording().getPeriodMedianPerSec(LLStatViewer::FPS))); + S32 vsync_freq=-1; + auto fps = LLTrace::get_frame_recording().getPeriodMedianPerSec(LLStatViewer::FPS); + if (gViewerWindow && gViewerWindow->getWindow()) + { + vsync_freq = gViewerWindow->getWindow()->getRefreshRate(); + } + mFPSText->setText(llformat("%.1f", fps )); + // if background, go grey, else go white unless we have a cap (checked next) + auto fps_color = FPS_uncapped_color; + if ((gViewerWindow && !gViewerWindow->getWindow()->getVisible()) + || !gFocusMgr.getAppHasFocus()) + { + fps_color = FPS_unfocussed_color; + } + else + { + if (limit_fps_enabled && max_fps > 0) + { + if (fps >= max_fps-1) // allow a small undershoot + { + fps_color = FPS_limit_reached_color; + } + else + { + fps_color = FPS_below_limit_color; + } + } + // use vsync if enabled and the freq is lower than the max_fps + if (vsync_enabled && vsync_freq > 0) + { + if ( !limit_fps_enabled || (limit_fps_enabled && vsync_freq < (S32)max_fps) ) + { + if (fps >= vsync_freq -1 ) + { + fps_color = vsync_limit_reached_color; + } + else + { + fps_color = FPS_below_limit_color; + } + } + } + } + mFPSText->setColor(fps_color); } // diff --git a/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml index 2c927502a1..de58146dc6 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml @@ -1110,6 +1110,47 @@ If you do not understand the distinction then leave this control alone." top_pad="6" width="256"/> + + + + + - - 200.0 From 47535db7e6b13ffa083c0c101e737e7c50f3ebe6 Mon Sep 17 00:00:00 2001 From: PanteraPolnocy Date: Sat, 9 Nov 2024 01:13:42 +0100 Subject: [PATCH 05/14] Apply change to all affected langauges... --- .../skins/default/xui/az/panel_preferences_graphics1.xml | 3 ++- .../skins/default/xui/de/panel_preferences_graphics1.xml | 3 ++- .../skins/default/xui/fr/panel_preferences_graphics1.xml | 3 ++- .../skins/default/xui/it/panel_preferences_graphics1.xml | 3 ++- .../skins/default/xui/ja/panel_preferences_graphics1.xml | 2 +- .../skins/default/xui/pl/panel_preferences_graphics1.xml | 3 ++- indra/newview/skins/default/xui/pl/panel_status_bar.xml | 2 +- .../skins/default/xui/ru/panel_preferences_graphics1.xml | 3 ++- 8 files changed, 14 insertions(+), 8 deletions(-) diff --git a/indra/newview/skins/default/xui/az/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/az/panel_preferences_graphics1.xml index 4131ddb6d3..0cf0751748 100644 --- a/indra/newview/skins/default/xui/az/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/az/panel_preferences_graphics1.xml @@ -127,6 +127,8 @@ Dünya yeniləməsi: + + Teksturların çəkilişi: @@ -150,7 +152,6 @@ - diff --git a/indra/newview/skins/default/xui/de/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/de/panel_preferences_graphics1.xml index c85c2c1aeb..25c7dc6565 100644 --- a/indra/newview/skins/default/xui/de/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/de/panel_preferences_graphics1.xml @@ -164,6 +164,8 @@ Welt-Aktualisierung: + + Textur-Darstellung: @@ -200,7 +202,6 @@ - diff --git a/indra/newview/skins/default/xui/fr/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/fr/panel_preferences_graphics1.xml index 76a86aa15d..5b2975e806 100644 --- a/indra/newview/skins/default/xui/fr/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/fr/panel_preferences_graphics1.xml @@ -125,6 +125,8 @@ Si vous ne comprenez pas la distinction, ne vous souciez pas de ce contrôle."/> Actualisation de l'univers : + + Rendu des textures : @@ -145,7 +147,6 @@ Si vous ne comprenez pas la distinction, ne vous souciez pas de ce contrôle."/> - diff --git a/indra/newview/skins/default/xui/it/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/it/panel_preferences_graphics1.xml index a3f03b3c1c..1a3a3ed170 100644 --- a/indra/newview/skins/default/xui/it/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/it/panel_preferences_graphics1.xml @@ -136,6 +136,8 @@ Caricamento del mondo: + + Rendering texture: @@ -168,7 +170,6 @@ - diff --git a/indra/newview/skins/default/xui/ja/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/ja/panel_preferences_graphics1.xml index 5f68a691c1..e3692b7a28 100644 --- a/indra/newview/skins/default/xui/ja/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/ja/panel_preferences_graphics1.xml @@ -168,6 +168,7 @@ + テクスチャ・レンダリング: @@ -201,7 +202,6 @@ - diff --git a/indra/newview/skins/default/xui/pl/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/pl/panel_preferences_graphics1.xml index c7e1074280..f5c8932532 100644 --- a/indra/newview/skins/default/xui/pl/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/pl/panel_preferences_graphics1.xml @@ -136,6 +136,8 @@ Odświeżanie świata: + + Rendering tekstur: @@ -168,7 +170,6 @@ - diff --git a/indra/newview/skins/default/xui/pl/panel_status_bar.xml b/indra/newview/skins/default/xui/pl/panel_status_bar.xml index f2f0c9e912..00601de2cc 100644 --- a/indra/newview/skins/default/xui/pl/panel_status_bar.xml +++ b/indra/newview/skins/default/xui/pl/panel_status_bar.xml @@ -27,6 +27,6 @@