From ad6dceb1c3e9024c93be6c7212b4d3687ca13e0d Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Wed, 27 Sep 2023 23:50:46 +0300 Subject: [PATCH 1/5] SL-15039 Fixed missed filter time variable --- indra/llui/llfolderviewmodel.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/indra/llui/llfolderviewmodel.cpp b/indra/llui/llfolderviewmodel.cpp index 93122503d1..394581d6d7 100644 --- a/indra/llui/llfolderviewmodel.cpp +++ b/indra/llui/llfolderviewmodel.cpp @@ -48,8 +48,8 @@ std::string LLFolderViewModelCommon::getStatusText() void LLFolderViewModelCommon::filter() { - static LLCachedControl max_time(*LLUI::getInstance()->mSettingGroups["config"], "FilterItemsMaxTimePerFrameVisible", 10); - getFilter().resetTime(llclamp(max_time(), 1, 100)); + const S32 MAX_FILTER_TIME = 10; + getFilter().resetTime(MAX_FILTER_TIME); mFolderView->getViewModelItem()->filter(getFilter()); } From ddd67c3eced1f23a373f730c5de0b6eebefe033a Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Thu, 28 Sep 2023 15:37:32 +0200 Subject: [PATCH 2/5] SL-20361 Avoid of ASSERT (false) in check_rigged_group() --- indra/newview/llspatialpartition.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 8bd40f2f31..b39fa769a0 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -1616,6 +1616,7 @@ void pushVertsColorCoded(LLSpatialGroup* group, U32 mask) // - a linked rigged drawable face has the wrong draw order index bool check_rigged_group(LLDrawable* drawable) { +#if 0 if (drawable->isState(LLDrawable::RIGGED)) { LLSpatialGroup* group = drawable->getSpatialGroup(); @@ -1671,7 +1672,7 @@ bool check_rigged_group(LLDrawable* drawable) } } } - +#endif return true; } From 18dc7d0c0bda3af4b20f670ee29701fa118e4b6d Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Mon, 25 Sep 2023 12:29:51 +0200 Subject: [PATCH 3/5] SL-20244 On-screen animesh characters that start pelvis offset animations disappear when root goes off-screen --- indra/newview/lldrawable.cpp | 13 ---------- indra/newview/llspatialpartition.cpp | 37 ++++++++++++++++++++++++++++ indra/newview/llspatialpartition.h | 5 +++- indra/newview/llvovolume.cpp | 22 ----------------- 4 files changed, 41 insertions(+), 36 deletions(-) diff --git a/indra/newview/lldrawable.cpp b/indra/newview/lldrawable.cpp index bb4174d3b6..d8be4c3bd5 100644 --- a/indra/newview/lldrawable.cpp +++ b/indra/newview/lldrawable.cpp @@ -763,19 +763,6 @@ void LLDrawable::movePartition() if (part) { part->move(this, getSpatialGroup()); - - // SL-18251 "On-screen animesh characters using pelvis offset animations - // disappear when root goes off-screen" - // - // Update extents of the root node when Control Avatar changes it's bounds - if (mRenderType == LLPipeline::RENDER_TYPE_CONTROL_AV && isRoot()) - { - LLControlAvatar* controlAvatar = dynamic_cast(getVObj().get()); - if (controlAvatar && controlAvatar->mControlAVBridge) - { - ((LLSpatialGroup*)controlAvatar->mControlAVBridge->mOctree->getListener(0))->setState(LLViewerOctreeGroup::DIRTY); - } - } } } diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index b39fa769a0..e19f8fef41 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -847,6 +847,43 @@ void LLSpatialGroup::handleChildAddition(const OctreeNode* parent, OctreeNode* c assert_states_valid(this); } +//virtual +void LLSpatialGroup::rebound() +{ + if (!isDirty()) + return; + + super::rebound(); + + if (mSpatialPartition->mDrawableType == LLPipeline::RENDER_TYPE_CONTROL_AV) + { + llassert(mSpatialPartition->mPartitionType == LLViewerRegion::PARTITION_CONTROL_AV); + + LLSpatialBridge* bridge = getSpatialPartition()->asBridge(); + if (bridge && + bridge->mDrawable && + bridge->mDrawable->getVObj() && + bridge->mDrawable->getVObj()->isRoot()) + { + LLControlAvatar* controlAvatar = bridge->mDrawable->getVObj()->getControlAvatar(); + if (controlAvatar && + controlAvatar->mDrawable && + controlAvatar->mControlAVBridge) + { + llassert(controlAvatar->mControlAVBridge->mOctree); + + LLSpatialGroup* root = (LLSpatialGroup*)controlAvatar->mControlAVBridge->mOctree->getListener(0); + if (this == root) + { + const LLVector4a* addingExtents = controlAvatar->mDrawable->getSpatialExtents(); + const LLXformMatrix* currentTransform = bridge->mDrawable->getXform(); + expandExtents(addingExtents, *currentTransform); + } + } + } + } +} + void LLSpatialGroup::destroyGL(bool keep_occlusion) { setState(LLSpatialGroup::GEOM_DIRTY | LLSpatialGroup::IMAGE_DIRTY); diff --git a/indra/newview/llspatialpartition.h b/indra/newview/llspatialpartition.h index cdb591083c..b5ac867b3e 100644 --- a/indra/newview/llspatialpartition.h +++ b/indra/newview/llspatialpartition.h @@ -205,6 +205,7 @@ public: LL_ALIGN_PREFIX(64) class LLSpatialGroup : public LLOcclusionCullingGroup { + using super = LLOcclusionCullingGroup; friend class LLSpatialPartition; friend class LLOctreeStateCheck; public: @@ -322,6 +323,9 @@ public: virtual void handleDestruction(const TreeNode* node); virtual void handleChildAddition(const OctreeNode* parent, OctreeNode* child); + // LLViewerOctreeGroup + virtual void rebound(); + public: LL_ALIGN_16(LLVector4a mViewAngle); LL_ALIGN_16(LLVector4a mLastUpdateViewAngle); @@ -703,7 +707,6 @@ class LLControlAVBridge : public LLVolumeBridge using super = LLVolumeBridge; public: LLControlAVBridge(LLDrawable* drawablep, LLViewerRegion* regionp); - virtual void updateSpatialExtents(); }; class LLHUDBridge : public LLVolumeBridge diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 4ddba872f1..c7054102fd 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -5110,28 +5110,6 @@ LLControlAVBridge::LLControlAVBridge(LLDrawable* drawablep, LLViewerRegion* regi mPartitionType = LLViewerRegion::PARTITION_CONTROL_AV; } -void LLControlAVBridge::updateSpatialExtents() -{ - LL_PROFILE_ZONE_SCOPED_CATEGORY_DRAWABLE - - LLControlAvatar* controlAvatar = getVObj()->getControlAvatar(); - - LLSpatialGroup* root = (LLSpatialGroup*)mOctree->getListener(0); - - bool rootWasDirty = root->isDirty(); - - super::updateSpatialExtents(); // root becomes non-dirty here - - // SL-18251 "On-screen animesh characters using pelvis offset animations - // disappear when root goes off-screen" - // - // Expand extents to include Control Avatar placed outside of the bounds - if (controlAvatar && (rootWasDirty || controlAvatar->mPlaying)) - { - root->expandExtents(controlAvatar->mDrawable->getSpatialExtents(), *mDrawable->getXform()); - } -} - bool can_batch_texture(LLFace* facep) { if (facep->getTextureEntry()->getBumpmap()) From 4b74b82f8d1d0b9fb57dd21e6bf3caad410dd691 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Fri, 29 Sep 2023 22:17:37 +0300 Subject: [PATCH 4/5] SL-20367 Click actions Zoom and Ignore can't be set from object's profile --- indra/newview/llsidepaneltaskinfo.cpp | 13 ++++++++----- .../skins/default/xui/en/sidepanel_task_info.xml | 8 ++++---- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/indra/newview/llsidepaneltaskinfo.cpp b/indra/newview/llsidepaneltaskinfo.cpp index 225751ab92..1103db9baa 100644 --- a/indra/newview/llsidepaneltaskinfo.cpp +++ b/indra/newview/llsidepaneltaskinfo.cpp @@ -855,11 +855,12 @@ void LLSidepanelTaskInfo::refresh() U8 click_action = 0; if (LLSelectMgr::getInstance()->selectionGetClickAction(&click_action)) { - LLComboBox* ComboClickAction = getChild("clickaction"); - if (ComboClickAction) - { - ComboClickAction->setCurrentByIndex((S32)click_action); - } + if (click_action > CLICK_ACTION_OPEN_MEDIA) + { + // Doesn't list media, nor play + click_action -= 2; + } + getChild("clickaction")->setCurrentByIndex((S32)click_action); } getChildView("label click action")->setEnabled(is_perm_modify && is_nonpermanent_enforced && all_volume); getChildView("clickaction")->setEnabled(is_perm_modify && is_nonpermanent_enforced && all_volume); @@ -1143,6 +1144,8 @@ static U8 string_value_to_click_action(std::string p_value) return CLICK_ACTION_ZOOM; if (p_value == "None") return CLICK_ACTION_DISABLED; + if (p_value == "Ignore") + return CLICK_ACTION_IGNORE; return CLICK_ACTION_TOUCH; } diff --git a/indra/newview/skins/default/xui/en/sidepanel_task_info.xml b/indra/newview/skins/default/xui/en/sidepanel_task_info.xml index 5f0241512a..91325369f5 100644 --- a/indra/newview/skins/default/xui/en/sidepanel_task_info.xml +++ b/indra/newview/skins/default/xui/en/sidepanel_task_info.xml @@ -299,14 +299,14 @@ label="Zoom" name="Zoom" value="Zoom" /> - + Date: Mon, 2 Oct 2023 21:56:06 +0300 Subject: [PATCH 5/5] SL-20367 Switch from index to value based selection To make sure it won't happen again once new option gets added --- indra/newview/llsidepaneltaskinfo.cpp | 33 ++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 6 deletions(-) diff --git a/indra/newview/llsidepaneltaskinfo.cpp b/indra/newview/llsidepaneltaskinfo.cpp index 1103db9baa..525dd760ad 100644 --- a/indra/newview/llsidepaneltaskinfo.cpp +++ b/indra/newview/llsidepaneltaskinfo.cpp @@ -73,6 +73,32 @@ LLSidepanelTaskInfo* LLSidepanelTaskInfo::sActivePanel = NULL; static LLPanelInjector t_task_info("sidepanel_task_info"); +static std::string click_action_to_string_value(U8 click_action) +{ + switch (click_action) + { + case CLICK_ACTION_TOUCH: + return "Touch"; + case CLICK_ACTION_SIT: + return "Sit"; + case CLICK_ACTION_BUY: + return "Buy"; + case CLICK_ACTION_PAY: + return "Pay"; + case CLICK_ACTION_OPEN: + return "Open"; + case CLICK_ACTION_ZOOM: + return "Zoom"; + case CLICK_ACTION_DISABLED: + return "None"; + case CLICK_ACTION_IGNORE: + return "Ignore"; + default: + return "Touch"; + } + return "Touch"; +} + // Default constructor LLSidepanelTaskInfo::LLSidepanelTaskInfo() { @@ -855,12 +881,7 @@ void LLSidepanelTaskInfo::refresh() U8 click_action = 0; if (LLSelectMgr::getInstance()->selectionGetClickAction(&click_action)) { - if (click_action > CLICK_ACTION_OPEN_MEDIA) - { - // Doesn't list media, nor play - click_action -= 2; - } - getChild("clickaction")->setCurrentByIndex((S32)click_action); + getChild("clickaction")->setValue(click_action_to_string_value(click_action)); } getChildView("label click action")->setEnabled(is_perm_modify && is_nonpermanent_enforced && all_volume); getChildView("clickaction")->setEnabled(is_perm_modify && is_nonpermanent_enforced && all_volume);