diff --git a/autobuild.xml b/autobuild.xml index 51997254c7..13dd558770 100644 --- a/autobuild.xml +++ b/autobuild.xml @@ -1320,9 +1320,9 @@ archive hash - 650e836255b6c2ecb93d3f1f7220051c + dce3f3c01fddb400cb143c3283fe9259 url - http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/55011/511905/glh_linear-0.0.0-common-538981.tar.bz2 + https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/82754/775367/glh_linear-0.0.0-common-560278.tar.bz2 name common diff --git a/doc/contributions.txt b/doc/contributions.txt index 0d85e46ef2..af97d1f75d 100755 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -285,6 +285,7 @@ Beq Janus SL-15709 SL-16021 SL-18202 + SL-18586 Beth Walcher Bezilon Kasei Biancaluce Robbiani diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index c301b25539..cc88cf9f4b 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -26239,17 +26239,6 @@ Change of this parameter will affect the layout of buttons in notification toast Value 473405 - FSUseCoRoFor360Capture - - Comment - Use co-routine to extract 360 photos. - Persist - 1 - Type - Boolean - Value - 0 - SDL2IMEDefaultVerticalOffset Comment diff --git a/indra/newview/lldrawpoolavatar.cpp b/indra/newview/lldrawpoolavatar.cpp index e047c4e55c..13bb10cc4e 100644 --- a/indra/newview/lldrawpoolavatar.cpp +++ b/indra/newview/lldrawpoolavatar.cpp @@ -394,7 +394,7 @@ void LLDrawPoolAvatar::renderShadow(S32 pass) LLVOAvatar::AvatarOverallAppearance oa = avatarp->getOverallAppearance(); BOOL impostor = !LLPipeline::sImpostorRender && avatarp->isImpostor(); // no shadows if the shadows are causing this avatar to breach the limit. - if (avatarp->isTooSlowWithShadows() || impostor || (oa == LLVOAvatar::AOA_INVISIBLE)) + if (avatarp->isTooSlow() || impostor || (oa == LLVOAvatar::AOA_INVISIBLE)) { // No shadows for impostored (including jellydolled) or invisible avs. return; diff --git a/indra/newview/llfloater360capture.cpp b/indra/newview/llfloater360capture.cpp index c36cd14467..108e2ed52f 100644 --- a/indra/newview/llfloater360capture.cpp +++ b/indra/newview/llfloater360capture.cpp @@ -323,25 +323,7 @@ const std::string LLFloater360Capture::getHTMLBaseFolder() // triggered when the 'capture' button in the UI is pressed void LLFloater360Capture::onCapture360ImagesBtn() { - // FIRE-31942 Avoid CoRo that appears to never usefully yield - // Allow option to re-enable on the off chance a low power machine can benefit - if(gSavedSettings.getBOOL("FSUseCoRoFor360Capture")) - { - // - // launch the main capture code in a coroutine so we can - // yield/suspend at some points to give the main UI - // thread a look-in occasionally. - LLCoros::instance().launch("capture360cap", [this]() - { - capture360Images(); - }); - // FIRE-31942 Avoid CoRo that appears to never usefully yield - } - else - { - capture360Images(); - } - // + capture360Images(); } // Gets the full path name for a given JavaScript file in the HTML folder. We @@ -696,10 +678,6 @@ void LLFloater360Capture::capture360Images() mCaptureBtn->setEnabled(true); mSaveLocalBtn->setEnabled(true); - // allow the UI to update by suspending and waiting for the - // main render loop to update the UI - if(gSavedSettings.getBOOL("FSUseCoRoFor360Capture")) // FIRE-31942 - make apparently pointless CoRo optional (just in case) - suspendForAFrame(); } // once the request is made to navigate to the web page containing the code diff --git a/indra/newview/llfloaterperformance.cpp b/indra/newview/llfloaterperformance.cpp index 10595f5b6a..36912971d9 100644 --- a/indra/newview/llfloaterperformance.cpp +++ b/indra/newview/llfloaterperformance.cpp @@ -262,7 +262,7 @@ void LLFloaterPerformance::populateHUDList() row[1]["column"] = "complex_value"; row[1]["type"] = "text"; - row[1]["value"] = llformat( "%.f",LLPerfStats::raw_to_us(hud_render_time_raw) ); + row[1]["value"] = llformat( "%.f", llmax(LLPerfStats::raw_to_us(hud_render_time_raw), (double)1)); row[1]["font"]["name"] = "SANSSERIF"; row[2]["column"] = "name"; @@ -321,7 +321,7 @@ void LLFloaterPerformance::populateObjectList() row[1]["column"] = "complex_value"; row[1]["type"] = "text"; - row[1]["value"] = llformat("%.f", LLPerfStats::raw_to_us(attach_render_time_raw)); + row[1]["value"] = llformat("%.f", llmax(LLPerfStats::raw_to_us(attach_render_time_raw), (double)1)); row[1]["font"]["name"] = "SANSSERIF"; row[2]["column"] = "name"; @@ -372,7 +372,7 @@ void LLFloaterPerformance::populateNearbyList() auto render_av_raw = LLPerfStats::StatsRecorder::get(AvType, avatar->getID(),LLPerfStats::StatType_t::RENDER_COMBINED); LLPerfStats::bufferToggleLock.unlock(); - auto is_slow = avatar->isTooSlowWithShadows(); + auto is_slow = avatar->isTooSlow(); LLSD item; item["id"] = avatar->getID(); LLSD& row = item["columns"]; diff --git a/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp b/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp index 3dddfed727..ad5edf0862 100644 --- a/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp +++ b/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp @@ -59,6 +59,7 @@ LLFloaterPreferenceGraphicsAdvanced::LLFloaterPreferenceGraphicsAdvanced(const L LLFloaterPreferenceGraphicsAdvanced::~LLFloaterPreferenceGraphicsAdvanced() { mComplexityChangedSignal.disconnect(); + mLODFactorChangedSignal.disconnect(); } BOOL LLFloaterPreferenceGraphicsAdvanced::postBuild() @@ -78,8 +79,8 @@ BOOL LLFloaterPreferenceGraphicsAdvanced::postBuild() use_HiDPI->setVisible(FALSE); #endif - mComplexityChangedSignal = gSavedSettings.getControl("RenderAvatarMaxComplexity")->getCommitSignal()->connect(boost::bind(&LLFloaterPreferenceGraphicsAdvanced::updateComplexityText, this)); - + mComplexityChangedSignal = gSavedSettings.getControl("RenderAvatarMaxComplexity")->getCommitSignal()->connect(boost::bind(&LLFloaterPreferenceGraphicsAdvanced::updateComplexityText, this)); + mLODFactorChangedSignal = gSavedSettings.getControl("RenderVolumeLODFactor")->getCommitSignal()->connect(boost::bind(&LLFloaterPreferenceGraphicsAdvanced::updateObjectMeshDetailText, this)); return TRUE; } @@ -165,6 +166,11 @@ void LLFloaterPreferenceGraphicsAdvanced::updateComplexityText() getChild("IndirectMaxComplexityText", true)); } +void LLFloaterPreferenceGraphicsAdvanced::updateObjectMeshDetailText() +{ + updateSliderText(getChild("ObjectMeshDetail", true), getChild("ObjectMeshDetailText", true)); +} + void LLFloaterPreferenceGraphicsAdvanced::updateSliderText(LLSliderCtrl* ctrl, LLTextBox* text_box) { if (text_box == NULL || ctrl== NULL) diff --git a/indra/newview/llfloaterpreferencesgraphicsadvanced.h b/indra/newview/llfloaterpreferencesgraphicsadvanced.h index 7f26ff8b00..2c92f3dbf1 100644 --- a/indra/newview/llfloaterpreferencesgraphicsadvanced.h +++ b/indra/newview/llfloaterpreferencesgraphicsadvanced.h @@ -49,6 +49,7 @@ public: void setMaxNonImpostorsText(U32 value, LLTextBox* text_box); void updateMaxComplexity(); void updateComplexityText(); + void updateObjectMeshDetailText(); void refresh(); // callback for when client modifies a render option void onRenderOptionEnable(); @@ -60,6 +61,7 @@ protected: void onBtnCancel(const LLSD& userdata); boost::signals2::connection mComplexityChangedSignal; + boost::signals2::connection mLODFactorChangedSignal; }; #endif //LLFLOATERPREFERENCEGRAPHICSADVANCED_H diff --git a/indra/newview/llperfstats.cpp b/indra/newview/llperfstats.cpp index c6871d0d93..a589d44636 100644 --- a/indra/newview/llperfstats.cpp +++ b/indra/newview/llperfstats.cpp @@ -54,6 +54,8 @@ namespace LLPerfStats std::mutex bufferToggleLock{}; F64 cpu_hertz{0.0}; // reinstate threadsafe frequency + F64 cpu_hertz{0.0}; + Tunables tunables; std::atomic StatsRecorder::writeBuffer{0}; @@ -137,7 +139,8 @@ namespace LLPerfStats // create a queue // create a thread to consume from the queue tunables.initialiseFromSettings(); - LLPerfStats::cpu_hertz = (F64)LLTrace::BlockTimer::countsPerSecond(); // reinstate threadsafe frequency + LLPerfStats::cpu_hertz = (F64)LLTrace::BlockTimer::countsPerSecond(); + t.detach(); } @@ -346,7 +349,7 @@ namespace LLPerfStats } // The frametime budget we have based on the target FPS selected - auto target_frame_time_raw = (U64)llround(LLPerfStats::cpu_hertz/(tunables.userTargetFPS==0?1:tunables.userTargetFPS));// reinstate threadsafe frequency + auto target_frame_time_raw = (U64)llround(LLPerfStats::cpu_hertz/(tunables.userTargetFPS==0?1:tunables.userTargetFPS)); // LL_INFOS() << "Effective FPS(raw):" << tot_frame_time_raw << " Target:" << target_frame_time_raw << LL_ENDL; auto inferredFPS{1000/(U32)std::max(raw_to_ms(tot_frame_time_raw),1.0)}; U32 settingsChangeFrequency{inferredFPS > 25?inferredFPS:25}; diff --git a/indra/newview/llperfstats.h b/indra/newview/llperfstats.h index e0414da759..d89ea2e1a0 100644 --- a/indra/newview/llperfstats.h +++ b/indra/newview/llperfstats.h @@ -78,6 +78,8 @@ namespace LLPerfStats static constexpr U32 TUNE_SCENE_AND_AVATARS{1}; extern F64 cpu_hertz; // reinstate thread safety + extern F64 cpu_hertz; + extern std::atomic tunedAvatars; extern std::atomic renderAvatarMaxART_ns; extern bool belowTargetFPS; @@ -525,15 +527,10 @@ namespace LLPerfStats StatsRecorder::send(std::move(stat)); }; }; - // use thread safe/low overhead cpu frequency tracking (might need to add refresh to this) - // inline double raw_to_ns(U64 raw) { return (static_cast(raw) * 1000000000.0) / (F64)LLTrace::BlockTimer::countsPerSecond(); }; - // inline double raw_to_us(U64 raw) { return (static_cast(raw) * 1000000.0) / (F64)LLTrace::BlockTimer::countsPerSecond(); }; - // inline double raw_to_ms(U64 raw) { return (static_cast(raw) * 1000.0) / (F64)LLTrace::BlockTimer::countsPerSecond(); }; inline double raw_to_ns(U64 raw) { return (static_cast(raw) * 1000000000.0) / LLPerfStats::cpu_hertz; }; inline double raw_to_us(U64 raw) { return (static_cast(raw) * 1000000.0) / LLPerfStats::cpu_hertz; }; inline double raw_to_ms(U64 raw) { return (static_cast(raw) * 1000.0) / LLPerfStats::cpu_hertz; }; - // using RecordSceneTime = RecordTime; using RecordAvatarTime = RecordTime; diff --git a/indra/newview/llviewerpartsim.cpp b/indra/newview/llviewerpartsim.cpp index b7fb127d23..f77ed8abaf 100644 --- a/indra/newview/llviewerpartsim.cpp +++ b/indra/newview/llviewerpartsim.cpp @@ -718,7 +718,7 @@ void LLViewerPartSim::updateSimulation() if (upd && vobj && (vobj->getPCode() == LL_PCODE_VOLUME)) { - if(vobj->getAvatar() && vobj->getAvatar()->isTooComplex() && vobj->getAvatar()->isTooSlowWithShadows()) + if(vobj->getAvatar() && vobj->getAvatar()->isTooComplex() && vobj->getAvatar()->isTooSlow()) { upd = FALSE; } diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index f725600165..c2c2ac07af 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -3359,7 +3359,7 @@ void LLVOAvatar::idleUpdateLoadingEffect() // Firestorm Clouds // do not generate particles for dummy or overly-complex avatars - if (!mIsDummy && !isTooComplex() && !isTooSlowWithShadows()) + if (!mIsDummy && !isTooComplex() && !isTooSlow()) { setParticleSource(sCloud, getID()); } @@ -9223,6 +9223,18 @@ bool LLVOAvatar::isTooComplex() const return too_complex; } +bool LLVOAvatar::isTooSlow() const +{ + static LLCachedControl always_render_friends(gSavedSettings, "AlwaysRenderFriends"); + bool render_friend = (LLAvatarTracker::instance().isBuddy(getID()) && always_render_friends); + + if (render_friend || mVisuallyMuteSetting == AV_ALWAYS_RENDER) + { + return false; + } + return mTooSlow; +} + // use Avatar Render Time as complexity metric // refactor for clarity post LL merge void LLVOAvatar::clearSlowARTCache() @@ -12468,7 +12480,7 @@ void LLVOAvatar::calcMutedAVColor() change_msg = " blocked: color is grey4"; } // we don't want jelly dolls - // else if (!isTooComplex() && !isTooSlowWithShadows()) + // else if (!isTooComplex() && !isTooSlow()) else if (!isTooComplex()) // { diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h index 78c4549651..a5d347e0c2 100644 --- a/indra/newview/llvoavatar.h +++ b/indra/newview/llvoavatar.h @@ -370,12 +370,10 @@ public: // check and return current state relative to limits // default will test only the geometry (combined=false). // this allows us to disable shadows separately on complex avatars. - inline bool isTooSlowWithShadows() const {return mTooSlow;}; + inline bool isTooSlowWithoutShadows() const {return mTooSlowWithoutShadows;}; - inline bool isTooSlow(bool combined = false) const - { - return(combined?mTooSlow:mTooSlowWithoutShadows); - } + bool isTooSlow() const; + void updateTooSlow(); virtual bool isTooComplex() const; // FIRE-29012: Standalone animesh avatars get affected by complexity limit; changed to virtual diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 731475a32a..2b551ea8e0 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -6223,7 +6223,7 @@ void LLPipeline::calcNearbyLights(LLCamera& camera) LLDrawable* drawable = light->drawable; const LLViewerObject *vobj = light->drawable->getVObj(); if(vobj && vobj->getAvatar() - && (vobj->getAvatar()->isTooComplex() || vobj->getAvatar()->isInMuteList() || vobj->getAvatar()->isTooSlowWithShadows()) + && (vobj->getAvatar()->isTooComplex() || vobj->getAvatar()->isInMuteList() || vobj->getAvatar()->isTooSlow()) ) { drawable->clearState(LLDrawable::NEARBY_LIGHT); @@ -6302,7 +6302,7 @@ void LLPipeline::calcNearbyLights(LLCamera& camera) continue; } LLVOAvatar * av = light->getAvatar(); - if (av && (av->isTooComplex() || av->isInMuteList() || av->isTooSlowWithShadows())) + if (av && (av->isTooComplex() || av->isInMuteList() || av->isTooSlow())) { // avatars that are already in the list will be removed by removeMutedAVsLights continue; diff --git a/indra/newview/skins/default/xui/en/floater_preferences_graphics_advanced.xml b/indra/newview/skins/default/xui/en/floater_preferences_graphics_advanced.xml index 48029a191d..4eb9165b05 100644 --- a/indra/newview/skins/default/xui/en/floater_preferences_graphics_advanced.xml +++ b/indra/newview/skins/default/xui/en/floater_preferences_graphics_advanced.xml @@ -522,8 +522,8 @@ label_width="185" layout="topleft" left="420" - min_val="1" - max_val="2" + min_val="0" + max_val="4" name="ObjectMeshDetail" show_text="false" top_delta="16"