diff --git a/indra/llcommon/indra_constants.cpp b/indra/llcommon/indra_constants.cpp index f3989ee1d0..90866631fe 100755 --- a/indra/llcommon/indra_constants.cpp +++ b/indra/llcommon/indra_constants.cpp @@ -67,3 +67,5 @@ const LLUUID TERRAIN_MOUNTAIN_DETAIL ("303cd381-8560-7579-23f1-f0a880799740"); / const LLUUID TERRAIN_ROCK_DETAIL ("53a2f406-4895-1d13-d541-d2e3b86bc19c"); // VIEWER const LLUUID DEFAULT_WATER_NORMAL ("822ded49-9a6c-f61c-cb89-6df54f42cdf4"); // VIEWER + +const LLUUID IMG_BLACK_SQUARE_MALEVICH ("3b39cc01-c2d1-e194-1181-e4404978b20c"); // On dataserver diff --git a/indra/llcommon/indra_constants.h b/indra/llcommon/indra_constants.h index b484b18d4f..01f091c5e0 100755 --- a/indra/llcommon/indra_constants.h +++ b/indra/llcommon/indra_constants.h @@ -208,6 +208,8 @@ LL_COMMON_API extern const LLUUID TERRAIN_ROCK_DETAIL; LL_COMMON_API extern const LLUUID DEFAULT_WATER_NORMAL; +LL_COMMON_API extern const LLUUID IMG_BLACK_SQUARE_MALEVICH; + // radius within which a chat message is fully audible const F32 CHAT_NORMAL_RADIUS = 20.f; diff --git a/indra/newview/llavatarrendernotifier.cpp b/indra/newview/llavatarrendernotifier.cpp index d3bc135b4c..ad5e3888b0 100644 --- a/indra/newview/llavatarrendernotifier.cpp +++ b/indra/newview/llavatarrendernotifier.cpp @@ -42,6 +42,7 @@ #include "llvoavatarself.h" #include "llviewercontrol.h" #include "lltrans.h" +#include "llagentcamera.h" // associated header #include "llavatarrendernotifier.h" @@ -104,6 +105,12 @@ std::string LLAvatarRenderNotifier::overLimitMessage() void LLAvatarRenderNotifier::displayNotification(bool show_over_limit) { + if (gAgentCamera.getLastCameraMode() == CAMERA_MODE_MOUSELOOK) + { + LL_WARNS("AvatarRenderInfo") << "Suppressing a notification while in mouselook" << LL_ENDL; + return; + } + mAgentComplexity = mLatestAgentComplexity; mShowOverLimitAgents = show_over_limit; static LLCachedControl expire_delay(gSavedSettings, "ShowMyComplexityChanges", 20); diff --git a/indra/newview/lldrawpoolavatar.cpp b/indra/newview/lldrawpoolavatar.cpp index 59c3f0d87a..3a091a5d01 100755 --- a/indra/newview/lldrawpoolavatar.cpp +++ b/indra/newview/lldrawpoolavatar.cpp @@ -1970,7 +1970,7 @@ void LLDrawPoolAvatar::renderRigged(LLVOAvatar* avatar, U32 type, bool glow) { //order is important here LLRender::DIFFUSE_MAP should be last, becouse it change //(gGL).mCurrTextureUnitIndex - gGL.getTexUnit(specular_channel)->bind(face->getTexture(LLRender::SPECULAR_MAP)); + gGL.getTexUnit(specular_channel)->bind(LLPipeline::sImpostorRender ? LLViewerTextureManager::findTexture(IMG_BLACK_SQUARE_MALEVICH) : face->getTexture(LLRender::SPECULAR_MAP)); gGL.getTexUnit(normal_channel)->bind(face->getTexture(LLRender::NORMAL_MAP)); gGL.getTexUnit(sDiffuseChannel)->bind(face->getTexture(LLRender::DIFFUSE_MAP), false, true); diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp index 3a7e9bc4ce..e30d3dfa6b 100644 --- a/indra/newview/llfloaterpreference.cpp +++ b/indra/newview/llfloaterpreference.cpp @@ -3953,12 +3953,10 @@ void LLPanelPreferenceGraphics::setPresetText() if (!preset_graphic_active.empty()) { - // Fix mapping to default preset when label is localized if (preset_graphic_active == PRESETS_DEFAULT) { preset_graphic_active = LLTrans::getString("Default"); } - // preset_text->setText(preset_graphic_active); } else diff --git a/indra/newview/llpanelpresetspulldown.cpp b/indra/newview/llpanelpresetspulldown.cpp index 175f281ca4..70f5fcd2c0 100644 --- a/indra/newview/llpanelpresetspulldown.cpp +++ b/indra/newview/llpanelpresetspulldown.cpp @@ -89,14 +89,18 @@ void LLPanelPresetsPulldown::populatePanel() row["columns"][0]["column"] = "preset_name"; row["columns"][0]["value"] = name; + bool is_selected_preset = false; if (name == gSavedSettings.getString("PresetGraphicActive")) { row["columns"][1]["column"] = "icon"; row["columns"][1]["type"] = "icon"; row["columns"][1]["value"] = "Check_Mark"; + + is_selected_preset = true; } - scroll->addElement(row); + LLScrollListItem* new_item = scroll->addElement(row); + new_item->setSelected(is_selected_preset); } } } diff --git a/indra/newview/llpresetsmanager.cpp b/indra/newview/llpresetsmanager.cpp index 70bbbc8fdb..633e0de411 100644 --- a/indra/newview/llpresetsmanager.cpp +++ b/indra/newview/llpresetsmanager.cpp @@ -134,19 +134,14 @@ void LLPresetsManager::loadPresetNamesFromDir(const std::string& dir, preset_nam presets = mPresetNames; } -// Fix mapping to default preset when label is localized -//bool LLPresetsManager::savePreset(const std::string& subdirectory, const std::string& name) bool LLPresetsManager::savePreset(const std::string& subdirectory, std::string name) -// { - // Fix mapping to default preset when label is localized if (LLTrans::getString(PRESETS_DEFAULT) == name) { name = PRESETS_DEFAULT; } - // - bool saved = false; + bool saved = false; std::vector name_list; if(PRESETS_GRAPHIC == subdirectory) @@ -254,17 +249,13 @@ void LLPresetsManager::setPresetNamesInComboBox(const std::string& subdirectory, } } -// Fix mapping to default preset when label is localized -//void LLPresetsManager::loadPreset(const std::string& subdirectory, const std::string& name) void LLPresetsManager::loadPreset(const std::string& subdirectory, std::string name) -// { - // Fix mapping to default preset when label is localized if (LLTrans::getString(PRESETS_DEFAULT) == name) { name = PRESETS_DEFAULT; } - // + std::string full_path(getPresetsDir(subdirectory) + gDirUtilp->getDirDelimiter() + LLURI::escape(name) + ".xml"); @@ -290,17 +281,12 @@ void LLPresetsManager::loadPreset(const std::string& subdirectory, std::string n } } -// Fix mapping to default preset when label is localized -//bool LLPresetsManager::deletePreset(const std::string& subdirectory, const std::string& name) bool LLPresetsManager::deletePreset(const std::string& subdirectory, std::string name) -// { - // Fix mapping to default preset when label is localized if (LLTrans::getString(PRESETS_DEFAULT) == name) { name = PRESETS_DEFAULT; } - // bool sts = true; diff --git a/indra/newview/llpresetsmanager.h b/indra/newview/llpresetsmanager.h index 5dbe97297f..ac4f0c010c 100644 --- a/indra/newview/llpresetsmanager.h +++ b/indra/newview/llpresetsmanager.h @@ -56,14 +56,9 @@ public: static std::string getPresetsDir(const std::string& subdirectory); void setPresetNamesInComboBox(const std::string& subdirectory, LLComboBox* combo, EDefaultOptions default_option); void loadPresetNamesFromDir(const std::string& dir, preset_name_list_t& presets, EDefaultOptions default_option); - // Fix mapping to default preset when label is localized - //bool savePreset(const std::string& subdirectory, const std::string & name); - //void loadPreset(const std::string& subdirectory, const std::string & name); - //bool deletePreset(const std::string& subdirectory, const std::string& name); bool savePreset(const std::string& subdirectory, std::string name); void loadPreset(const std::string& subdirectory, std::string name); bool deletePreset(const std::string& subdirectory, std::string name); - // // Emitted when a preset gets loaded, deleted, or saved. boost::signals2::connection setPresetListChangeCallback(const preset_list_signal_t::slot_type& cb); diff --git a/indra/newview/llstatusbar.cpp b/indra/newview/llstatusbar.cpp index e9aedf0f5d..bdd44d181a 100755 --- a/indra/newview/llstatusbar.cpp +++ b/indra/newview/llstatusbar.cpp @@ -618,6 +618,7 @@ void LLStatusBar::setVisibleForMouselook(bool visible) mSearchPanel->setVisible(visible && gSavedSettings.getBOOL("FSMenuSearch")); mTimeMediaPanel->setVisible(visible); setBackgroundVisible(visible); + mIconPresets->setVisible(visible); } void LLStatusBar::debitBalance(S32 debit) diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp index b9f9d298b4..c758ab0191 100755 --- a/indra/newview/llviewerobject.cpp +++ b/indra/newview/llviewerobject.cpp @@ -5141,10 +5141,7 @@ void LLViewerObject::updateText() LLVOAvatar* avatar = getAvatar(); if (avatar) { - // Use cached mutelist check - //mText->setHidden(LLMuteList::getInstance()->isMuted(avatar->getID())); mText->setHidden(avatar->isInMuteList()); - // } LLVector3 up_offset(0,0,0); diff --git a/indra/newview/llviewerpartsim.cpp b/indra/newview/llviewerpartsim.cpp index f4efc218c0..4879ea4d03 100755 --- a/indra/newview/llviewerpartsim.cpp +++ b/indra/newview/llviewerpartsim.cpp @@ -39,6 +39,7 @@ #include "llworld.h" #include "pipeline.h" #include "llspatialpartition.h" +#include "llvoavatarself.h" #include "llvovolume.h" const F32 PART_SIM_BOX_SIDE = 16.f; @@ -706,16 +707,18 @@ void LLViewerPartSim::updateSimulation() if (!mViewerPartSources[i]->isDead()) { BOOL upd = TRUE; - if (!LLPipeline::sRenderAttachedParticles) + LLViewerObject* vobj = mViewerPartSources[i]->mSourceObjectp; + if (vobj && (vobj->getPCode() == LL_PCODE_VOLUME)) { - LLViewerObject* vobj = mViewerPartSources[i]->mSourceObjectp; - if (vobj && (vobj->getPCode() == LL_PCODE_VOLUME)) + if(vobj->getAvatar() && vobj->getAvatar()->isTooComplex()) { - LLVOVolume* vvo = (LLVOVolume *)vobj; - if (vvo && vvo->isAttachment()) - { - upd = FALSE; - } + upd = FALSE; + } + + LLVOVolume* vvo = (LLVOVolume *)vobj; + if (!LLPipeline::sRenderAttachedParticles && vvo && vvo->isAttachment()) + { + upd = FALSE; } } diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 73eb53f59c..674dc3be70 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -739,10 +739,8 @@ LLVOAvatar::LLVOAvatar(const LLUUID& id, // [Legacy Bake] mLastUpdateRequestCOFVersion(-1), mLastUpdateReceivedCOFVersion(-1), - // Re-add mute list caching mCachedMuteListUpdateTime(0), mCachedInMuteList(false) - // { LL_DEBUGS("AvatarRender") << "LLVOAvatar Constructor (0x" << this << ") id:" << mID << LL_ENDL; @@ -2953,10 +2951,7 @@ void LLVOAvatar::idleUpdateNameTagText(BOOL new_name) } else { - // Performance tweak - //is_muted = LLMuteList::getInstance()->isMuted(getID()); is_muted = isInMuteList(); - // } // bool is_friend = LLAvatarTracker::instance().isBuddy(getID()); // [RLVa:KB] - Checked: 2010-10-31 (RLVa-1.2.2a) | Added: RLVa-1.2.2a @@ -3546,10 +3541,7 @@ void LLVOAvatar::slamPosition() mRoot->updateWorldMatrixChildren(); } -// FIRE-11783: Always visually mute avatars that are muted -//bool LLVOAvatar::isVisuallyMuted() const bool LLVOAvatar::isVisuallyMuted() -// { bool muted = false; @@ -3576,7 +3568,7 @@ bool LLVOAvatar::isVisuallyMuted() muted = true; } // FIRE-11783: Always visually mute avatars that are muted - //else if (LLMuteList::getInstance()->isMuted(getID())) + //else if (isInMuteList()) //{ // muted = true; //} @@ -3590,6 +3582,25 @@ bool LLVOAvatar::isVisuallyMuted() return muted; } +bool LLVOAvatar::isInMuteList() +{ + bool muted = false; + F64 now = LLFrameTimer::getTotalSeconds(); + if (now < mCachedMuteListUpdateTime) + { + muted = mCachedInMuteList; + } + else + { + muted = LLMuteList::getInstance()->isMuted(getID()); + + const F64 SECONDS_BETWEEN_MUTE_UPDATES = 1; + mCachedMuteListUpdateTime = now + SECONDS_BETWEEN_MUTE_UPDATES; + mCachedInMuteList = muted; + } + return muted; +} + // Re-add mute list caching bool LLVOAvatar::isInMuteList() { diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h index 567e4d0a5c..d9298834f1 100644 --- a/indra/newview/llvoavatar.h +++ b/indra/newview/llvoavatar.h @@ -399,11 +399,8 @@ public: public: U32 renderImpostor(LLColor4U color = LLColor4U(255,255,255,255), S32 diffuse_channel = 0); - // Re-add mute list caching - //bool isVisuallyMuted() const; bool isVisuallyMuted(); bool isInMuteList(); - // void forceUpdateVisualMuteSettings(); enum VisualMuteSettings @@ -442,10 +439,8 @@ public: mutable bool mVisualComplexityStale; U32 mReportedVisualComplexity; // from other viewers through the simulator - // Re-add mute list caching bool mCachedInMuteList; F64 mCachedMuteListUpdateTime; - // VisualMuteSettings mVisuallyMuteSetting; // Always or never visually mute this AV