From 79fe883ab68a9cdeefc015f0540344db6547e1f2 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Wed, 27 Nov 2024 15:07:54 +0200 Subject: viewer#3147 Thumbnail picker's image is grey #2 Apparently made a blunder in previous commit since I missed mFetchState being reset each run --- indra/newview/lltexturefetch.cpp | 20 +++++++++++++------- indra/newview/lltexturefetch.h | 2 +- indra/newview/llviewertexture.cpp | 3 ++- 3 files changed, 16 insertions(+), 9 deletions(-) (limited to 'indra') diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp index dd1be028cd..5172fad29d 100644 --- a/indra/newview/lltexturefetch.cpp +++ b/indra/newview/lltexturefetch.cpp @@ -1503,18 +1503,13 @@ bool LLTextureFetchWorker::doWork(S32 param) { if (http_not_found == mGetStatus) { - if (mFTType != FTT_MAP_TILE) - { - LL_WARNS(LOG_TXT) << "Texture missing from server (404): " << mUrl << LL_ENDL; - } - if(mWriteToCacheState == NOT_WRITE) //map tiles or server bakes { setState(DONE); releaseHttpSemaphore(); if (mFTType != FTT_MAP_TILE) { - LL_WARNS(LOG_TXT) << mID << " abort: WAIT_HTTP_REQ not found" << LL_ENDL; + LL_WARNS(LOG_TXT) << mID << "NOT_WRITE texture missing from server (404), abort: " << mUrl << LL_ENDL; } return true; } @@ -1524,6 +1519,10 @@ bool LLTextureFetchWorker::doWork(S32 param) LLViewerRegion* region = getRegion(); if (!region || mLastRegionId != region->getRegionID()) { + if (mFTType != FTT_MAP_TILE) + { + LL_INFOS(LOG_TXT) << "Texture missing from server (404), retrying: " << mUrl << " mRetryAttempt " << mRetryAttempt << LL_ENDL; + } // cap failure? try on new region. mUrl.clear(); ++mRetryAttempt; @@ -1532,6 +1531,11 @@ bool LLTextureFetchWorker::doWork(S32 param) return false; } } + + if (mFTType != FTT_MAP_TILE) + { + LL_WARNS(LOG_TXT) << "Texture missing from server (404): " << mUrl << LL_ENDL; + } } else if (http_service_unavail == mGetStatus) { @@ -2734,7 +2738,7 @@ LLTextureFetchWorker* LLTextureFetch::getWorker(const LLUUID& id) // Threads: T* -bool LLTextureFetch::getRequestFinished(const LLUUID& id, S32& discard_level, +bool LLTextureFetch::getRequestFinished(const LLUUID& id, S32& discard_level, S32& worker_state, LLPointer& raw, LLPointer& aux, LLCore::HttpStatus& last_http_get_status) { @@ -2743,6 +2747,7 @@ bool LLTextureFetch::getRequestFinished(const LLUUID& id, S32& discard_level, LLTextureFetchWorker* worker = getWorker(id); if (worker) { + worker_state = worker->mState; if (worker->wasAborted()) { res = true; @@ -2821,6 +2826,7 @@ bool LLTextureFetch::getRequestFinished(const LLUUID& id, S32& discard_level, } else { + worker_state = 0; res = true; } return res; diff --git a/indra/newview/lltexturefetch.h b/indra/newview/lltexturefetch.h index 3405f76e37..c2c5ec5acc 100644 --- a/indra/newview/lltexturefetch.h +++ b/indra/newview/lltexturefetch.h @@ -95,7 +95,7 @@ public: // Threads: T* // keep in mind that if fetcher isn't done, it still might need original raw image - bool getRequestFinished(const LLUUID& id, S32& discard_level, + bool getRequestFinished(const LLUUID& id, S32& discard_level, S32& worker_state, LLPointer& raw, LLPointer& aux, LLCore::HttpStatus& last_http_get_status); diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp index d2511aef7b..00e1ea4cd3 100644 --- a/indra/newview/llviewertexture.cpp +++ b/indra/newview/llviewertexture.cpp @@ -1872,7 +1872,7 @@ bool LLViewerFetchedTexture::updateFetch() if (mRawImage.notNull()) sRawCount--; if (mAuxRawImage.notNull()) sAuxCount--; // keep in mind that fetcher still might need raw image, don't modify original - bool finished = LLAppViewer::getTextureFetch()->getRequestFinished(getID(), fetch_discard, mRawImage, mAuxRawImage, + bool finished = LLAppViewer::getTextureFetch()->getRequestFinished(getID(), fetch_discard, mFetchState, mRawImage, mAuxRawImage, mLastHttpGetStatus); if (mRawImage.notNull()) sRawCount++; if (mAuxRawImage.notNull()) @@ -1979,6 +1979,7 @@ bool LLViewerFetchedTexture::updateFetch() << " mRawDiscardLevel " << mRawDiscardLevel << " current_discard " << current_discard << " stats " << mLastHttpGetStatus.toHex() + << " worker state " << mFetchState << LL_ENDL; } setIsMissingAsset(); -- cgit v1.2.3 From fd0389c9f04dac4b0e4ad13d10e520aad5cb2e61 Mon Sep 17 00:00:00 2001 From: "Jonathan \"Geenz\" Goodman" Date: Wed, 27 Nov 2024 16:39:25 -0500 Subject: Set vintage mode on Low+, and otherwise don't touch it for higher quality modes. --- indra/newview/featuretable.txt | 23 ++--------------------- indra/newview/featuretable_mac.txt | 9 ++------- 2 files changed, 4 insertions(+), 28 deletions(-) (limited to 'indra') diff --git a/indra/newview/featuretable.txt b/indra/newview/featuretable.txt index bd7c11a52f..fceb81f061 100644 --- a/indra/newview/featuretable.txt +++ b/indra/newview/featuretable.txt @@ -1,4 +1,4 @@ -version 71 +version 72 // The version number above should be incremented IF AND ONLY IF some // change has been made that is sufficiently important to justify // resetting the graphics preferences of all users to the recommended @@ -127,8 +127,6 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderEnableEmissiveBuffer 1 0 -RenderHDREnabled 1 0 RenderVintageMode 1 1 // @@ -170,9 +168,7 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderEnableEmissiveBuffer 1 1 -RenderHDREnabled 1 1 -RenderVintageMode 1 0 +RenderVintageMode 1 1 // // Medium Graphics Settings (standard) @@ -213,9 +209,6 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderEnableEmissiveBuffer 1 1 -RenderHDREnabled 1 1 -RenderVintageMode 1 0 // // Medium High Graphics Settings @@ -256,9 +249,6 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderEnableEmissiveBuffer 1 1 -RenderHDREnabled 1 1 -RenderVintageMode 1 0 // // High Graphics Settings (SSAO + sun shadows) @@ -299,9 +289,6 @@ RenderCASSharpness 1 0.4 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderEnableEmissiveBuffer 1 1 -RenderHDREnabled 1 1 -RenderVintageMode 1 0 // // High Ultra Graphics Settings (deferred + SSAO + all shadows) @@ -342,9 +329,6 @@ RenderCASSharpness 1 0.4 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderEnableEmissiveBuffer 1 1 -RenderHDREnabled 1 1 -RenderVintageMode 1 0 // // Ultra graphics (REALLY PURTY!) @@ -385,9 +369,6 @@ RenderCASSharpness 1 0.4 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderEnableEmissiveBuffer 1 1 -RenderHDREnabled 1 1 -RenderVintageMode 1 0 // // Class Unknown Hardware (unknown) diff --git a/indra/newview/featuretable_mac.txt b/indra/newview/featuretable_mac.txt index 3768f3b972..079e01076f 100644 --- a/indra/newview/featuretable_mac.txt +++ b/indra/newview/featuretable_mac.txt @@ -1,4 +1,4 @@ -version 65 +version 66 // The version number above should be incremented IF AND ONLY IF some // change has been made that is sufficiently important to justify // resetting the graphics preferences of all users to the recommended @@ -165,7 +165,7 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderVintageMode 1 0 +RenderVintageMode 1 1 // // Medium Graphics Settings (standard) @@ -206,7 +206,6 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderVintageMode 1 0 // // Medium High Graphics Settings @@ -247,7 +246,6 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderVintageMode 1 0 // // High Graphics Settings (SSAO + sun shadows) @@ -288,7 +286,6 @@ RenderCASSharpness 1 0 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderVintageMode 1 0 // // High Ultra Graphics Settings (SSAO + all shadows) @@ -329,7 +326,6 @@ RenderCASSharpness 1 0.4 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderVintageMode 1 0 // // Ultra graphics (REALLY PURTY!) @@ -370,7 +366,6 @@ RenderCASSharpness 1 0.4 RenderExposure 1 1 RenderTonemapType 1 1 RenderTonemapMix 1 0.7 -RenderVintageMode 1 0 // // Class Unknown Hardware (unknown) -- cgit v1.2.3 From a13ae880af287bf595095f3ff515cf31cd302fa5 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 27 Nov 2024 14:56:05 -0500 Subject: Add diagnostic output for LLProcess event history failure. --- indra/llcommon/tests/llprocess_test.cpp | 148 ++++++++++++++++++++------------ 1 file changed, 93 insertions(+), 55 deletions(-) (limited to 'indra') diff --git a/indra/llcommon/tests/llprocess_test.cpp b/indra/llcommon/tests/llprocess_test.cpp index 6e8422ca0c..b63cc52bec 100644 --- a/indra/llcommon/tests/llprocess_test.cpp +++ b/indra/llcommon/tests/llprocess_test.cpp @@ -1085,7 +1085,27 @@ namespace tut return false; } - std::list mHistory; + template + void checkHistory(CALLABLE&& code) + { + try + { + // we expect this lambda to contain tut::ensure() calls + std::forward(code)(mHistory); + } + catch (const failure&) + { + LL_INFOS() << "event history:" << LL_ENDL; + for (const LLSD& item : mHistory) + { + LL_INFOS() << item << LL_ENDL; + } + throw; + } + } + + using Listory = std::list; + Listory mHistory; LLTempBoundListener mConnection; }; @@ -1136,23 +1156,26 @@ namespace tut // finish out the run waitfor(*py.mPy); // now verify history - std::list::const_iterator li(listener.mHistory.begin()), - lend(listener.mHistory.end()); - ensure("no events", li != lend); - ensure_equals("history[0]", (*li)["data"].asString(), "abc"); - ensure_equals("history[0] len", (*li)["len"].asInteger(), 3); - ++li; - ensure("only 1 event", li != lend); - ensure_equals("history[1]", (*li)["data"].asString(), "abcdef"); - ensure_equals("history[0] len", (*li)["len"].asInteger(), 6); - ++li; - ensure("only 2 events", li != lend); - ensure_equals("history[2]", (*li)["data"].asString(), "abcdefghi" EOL); - ensure_equals("history[0] len", (*li)["len"].asInteger(), 9 + sizeof(EOL) - 1); - ++li; - // We DO NOT expect a whole new event for the second line because we - // disconnected. - ensure("more than 3 events", li == lend); + listener.checkHistory( + [](const EventListener::Listory& history) + { + auto li(history.begin()), lend(history.end()); + ensure("no events", li != lend); + ensure_equals("history[0]", (*li)["data"].asString(), "abc"); + ensure_equals("history[0] len", (*li)["len"].asInteger(), 3); + ++li; + ensure("only 1 event", li != lend); + ensure_equals("history[1]", (*li)["data"].asString(), "abcdef"); + ensure_equals("history[0] len", (*li)["len"].asInteger(), 6); + ++li; + ensure("only 2 events", li != lend); + ensure_equals("history[2]", (*li)["data"].asString(), "abcdefghi" EOL); + ensure_equals("history[0] len", (*li)["len"].asInteger(), 9 + sizeof(EOL) - 1); + ++li; + // We DO NOT expect a whole new event for the second line because we + // disconnected. + ensure("more than 3 events", li == lend); + }); } template<> template<> @@ -1172,14 +1195,17 @@ namespace tut // (or any other intervening layer) does crazy buffering. What we want // to ensure is that there was exactly ONE event with "eof" true, and // that it was the LAST event. - std::list::const_reverse_iterator rli(listener.mHistory.rbegin()), - rlend(listener.mHistory.rend()); - ensure("no events", rli != rlend); - ensure("last event not \"eof\"", (*rli)["eof"].asBoolean()); - while (++rli != rlend) - { - ensure("\"eof\" event not last", ! (*rli)["eof"].asBoolean()); - } + listener.checkHistory( + [](const EventListener::Listory& history) + { + auto rli(history.rbegin()), rlend(history.rend()); + ensure("no events", rli != rlend); + ensure("last event not \"eof\"", (*rli)["eof"].asBoolean()); + while (++rli != rlend) + { + ensure("\"eof\" event not last", ! (*rli)["eof"].asBoolean()); + } + }); } template<> template<> @@ -1202,13 +1228,17 @@ namespace tut ensure_equals("getLimit() after setlimit(10)", childout.getLimit(), 10); // okay, pump I/O to pick up output from child waitfor(*py.mPy); - ensure("no events", ! listener.mHistory.empty()); - // For all we know, that data could have arrived in several different - // bursts... probably not, but anyway, only check the last one. - ensure_equals("event[\"len\"]", - listener.mHistory.back()["len"].asInteger(), abc.length()); - ensure_equals("length of setLimit(10) data", - listener.mHistory.back()["data"].asString().length(), 10); + listener.checkHistory( + [abc](const EventListener::Listory& history) + { + ensure("no events", ! history.empty()); + // For all we know, that data could have arrived in several different + // bursts... probably not, but anyway, only check the last one. + ensure_equals("event[\"len\"]", + history.back()["len"].asInteger(), abc.length()); + ensure_equals("length of setLimit(10) data", + history.back()["data"].asString().length(), 10); + }); } template<> template<> @@ -1275,18 +1305,22 @@ namespace tut params.postend = pumpname; LLProcessPtr child = LLProcess::create(params); ensure("shouldn't have launched", ! child); - ensure_equals("number of postend events", listener.mHistory.size(), 1); - LLSD postend(listener.mHistory.front()); - ensure("has id", ! postend.has("id")); - ensure_equals("desc", postend["desc"].asString(), std::string(params.desc)); - ensure_equals("state", postend["state"].asInteger(), LLProcess::UNSTARTED); - ensure("has data", ! postend.has("data")); - std::string error(postend["string"]); - // All we get from canned parameter validation is a bool, so the - // "validation failed" message we ourselves generate can't mention - // "executable" by name. Just check that it's nonempty. - //ensure_contains("error", error, "executable"); - ensure("string", ! error.empty()); + listener.checkHistory( + [¶ms](const EventListener::Listory& history) + { + ensure_equals("number of postend events", history.size(), 1); + LLSD postend(history.front()); + ensure("has id", ! postend.has("id")); + ensure_equals("desc", postend["desc"].asString(), std::string(params.desc)); + ensure_equals("state", postend["state"].asInteger(), LLProcess::UNSTARTED); + ensure("has data", ! postend.has("data")); + std::string error(postend["string"]); + // All we get from canned parameter validation is a bool, so the + // "validation failed" message we ourselves generate can't mention + // "executable" by name. Just check that it's nonempty. + //ensure_contains("error", error, "executable"); + ensure("string", ! error.empty()); + }); } template<> template<> @@ -1308,16 +1342,20 @@ namespace tut { yield(); } - ensure("no postend event", i < timeout); - ensure_equals("number of postend events", listener.mHistory.size(), 1); - LLSD postend(listener.mHistory.front()); - ensure_equals("id", postend["id"].asInteger(), childid); - ensure("desc empty", ! postend["desc"].asString().empty()); - ensure_equals("state", postend["state"].asInteger(), LLProcess::EXITED); - ensure_equals("data", postend["data"].asInteger(), 35); - std::string str(postend["string"]); - ensure_contains("string", str, "exited"); - ensure_contains("string", str, "35"); + listener.checkHistory( + [i, timeout, childid](const EventListener::Listory& history) + { + ensure("no postend event", i < timeout); + ensure_equals("number of postend events", history.size(), 1); + LLSD postend(history.front()); + ensure_equals("id", postend["id"].asInteger(), childid); + ensure("desc empty", ! postend["desc"].asString().empty()); + ensure_equals("state", postend["state"].asInteger(), LLProcess::EXITED); + ensure_equals("data", postend["data"].asInteger(), 35); + std::string str(postend["string"]); + ensure_contains("string", str, "exited"); + ensure_contains("string", str, "35"); + }); } struct PostendListener -- cgit v1.2.3 From 6128a7dea713fdc01ae7a253dac2bb99dd585873 Mon Sep 17 00:00:00 2001 From: "Jonathan \"Geenz\" Goodman" Date: Wed, 27 Nov 2024 17:41:44 -0500 Subject: Make sure CAS controls are not active with vintage mode. (#3176) Also make extra sure vintage mode is enabled when GL3 is detected. --- indra/newview/llfeaturemanager.cpp | 3 +++ indra/newview/llfloaterpreferencesgraphicsadvanced.cpp | 2 ++ 2 files changed, 5 insertions(+) (limited to 'indra') diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp index 2ad1257695..22ba20100e 100644 --- a/indra/newview/llfeaturemanager.cpp +++ b/indra/newview/llfeaturemanager.cpp @@ -717,6 +717,9 @@ void LLFeatureManager::applyBaseMasks() // make sure to disable background context activity in GL3 mode LLImageGLThread::sEnabledMedia = false; LLImageGLThread::sEnabledTextures = false; + + // Make extra sure that vintage mode also gets enabled. + gSavedSettings.setBOOL("RenderVintageMode", true); } // now mask by gpu string diff --git a/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp b/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp index 65f3cc5db4..89ff9988a6 100644 --- a/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp +++ b/indra/newview/llfloaterpreferencesgraphicsadvanced.cpp @@ -271,6 +271,7 @@ void LLFloaterPreferenceGraphicsAdvanced::disableUnavailableSettings() LLCheckBoxCtrl* ctrl_dof = getChild("UseDoF"); LLSliderCtrl* sky = getChild("SkyMeshDetail"); LLTextBox* sky_text = getChild("SkyMeshDetailText"); + LLSliderCtrl* cas_slider = getChild("RenderSharpness"); // disabled windlight if (!LLFeatureManager::getInstance()->isFeatureAvailable("WindLightUseAtmosShaders")) @@ -330,6 +331,7 @@ void LLFloaterPreferenceGraphicsAdvanced::disableUnavailableSettings() tonemapLabel->setEnabled(!is_vintage); tonemapMix->setEnabled(!is_vintage); exposureSlider->setEnabled(!is_vintage); + cas_slider->setEnabled(!is_vintage); } void LLFloaterPreferenceGraphicsAdvanced::refreshEnabledState() -- cgit v1.2.3 From 9321f8e3a97825fe71756636b3500f5a8c7527ff Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Thu, 28 Nov 2024 00:02:42 +0200 Subject: viewer#3171 Exposure setting enabled in Vintage mode --- indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml | 1 + 1 file changed, 1 insertion(+) (limited to 'indra') 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 0c3b2c999a..1d4577f8ee 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml @@ -327,6 +327,7 @@