From 47cfa59c9b81f8e13ecb3377fb279261d985d1dc Mon Sep 17 00:00:00 2001 From: Rye Mutt <rye@alchemyviewer.org> Date: Fri, 4 Mar 2022 15:41:37 -0500 Subject: [PATCH] More opensim changes --- indra/newview/llviewerregion.cpp | 11 +++++++++++ indra/newview/llviewerregion.h | 2 ++ 2 files changed, 13 insertions(+) diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp index cb51eee8953..902ff453f3f 100644 --- a/indra/newview/llviewerregion.cpp +++ b/indra/newview/llviewerregion.cpp @@ -647,6 +647,11 @@ LLViewerRegion::LLViewerRegion(const U64 &handle, // Create the object lists initStats(); + initPartitions(); +} + +void LLViewerRegion::initPartitions() +{ //create object partitions //MUST MATCH declaration of eObjectPartitions @@ -669,6 +674,12 @@ LLViewerRegion::LLViewerRegion(const U64 &handle, setCapabilitiesReceivedCallback(boost::bind(&LLAvatarRenderInfoAccountant::scanNewRegion, _1)); } +void LLViewerRegion::reInitPartitions() +{ + std::for_each(mImpl->mObjectPartition.begin(), mImpl->mObjectPartition.end(), DeletePointer()); + mImpl->mObjectPartition.clear(); + initPartitions(); +} void LLViewerRegion::initStats() { diff --git a/indra/newview/llviewerregion.h b/indra/newview/llviewerregion.h index 24952373cf4..bc368d6bcdc 100644 --- a/indra/newview/llviewerregion.h +++ b/indra/newview/llviewerregion.h @@ -458,10 +458,12 @@ class LLViewerRegion final : public LLCapabilityProvider // implements this inte }; void showReleaseNotes(); + void reInitPartitions(); protected: void disconnectAllNeighbors(); void initStats(); + void initPartitions(); public: LLWind mWind; -- GitLab