summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorRichard Linden <none@none>2014-02-06 11:27:47 -0800
committerRichard Linden <none@none>2014-02-06 11:27:47 -0800
commit7b9e17f5cd4578c989385edd39e79e887c9ddc0d (patch)
tree0f740280b15bbc079fd97f93b32e2372106bf378 /indra
parent3040b429a3b136b87ddb0ae88ccfa3a7aa71e232 (diff)
parentb5389618f3744464760bbe1a54b49750d211a1ac (diff)
Merge
Diffstat (limited to 'indra')
-rwxr-xr-xindra/llmath/llvolume.cpp1
-rwxr-xr-xindra/newview/llflexibleobject.cpp10
-rwxr-xr-xindra/newview/llflexibleobject.h2
-rwxr-xr-xindra/newview/llvocache.cpp14
4 files changed, 16 insertions, 11 deletions
diff --git a/indra/llmath/llvolume.cpp b/indra/llmath/llvolume.cpp
index e419d1aea5..f0cff6e5cd 100755
--- a/indra/llmath/llvolume.cpp
+++ b/indra/llmath/llvolume.cpp
@@ -2086,6 +2086,7 @@ void LLVolume::resizePath(S32 length)
{
mPathp->resizePath(length);
mVolumeFaces.clear();
+ setDirty();
}
void LLVolume::regen()
diff --git a/indra/newview/llflexibleobject.cpp b/indra/newview/llflexibleobject.cpp
index 3cd4367891..b64034b945 100755
--- a/indra/newview/llflexibleobject.cpp
+++ b/indra/newview/llflexibleobject.cpp
@@ -722,13 +722,17 @@ void LLVolumeImplFlexible::preRebuild()
if (!mUpdated)
{
LL_RECORD_BLOCK_TIME(FTM_FLEXI_PREBUILD);
- doFlexibleRebuild();
+ doFlexibleRebuild(false);
}
}
-void LLVolumeImplFlexible::doFlexibleRebuild()
+void LLVolumeImplFlexible::doFlexibleRebuild(bool rebuild_volume)
{
LLVolume* volume = mVO->getVolume();
+ if(rebuild_volume)
+ {
+ volume->setDirty();
+ }
volume->regen();
mUpdated = TRUE;
@@ -801,7 +805,7 @@ BOOL LLVolumeImplFlexible::doUpdateGeometry(LLDrawable *drawable)
volume->dirtySpatialGroup();
{
LL_RECORD_BLOCK_TIME(FTM_FLEXIBLE_REBUILD);
- doFlexibleRebuild();
+ doFlexibleRebuild(volume->mVolumeChanged);
}
volume->genBBoxes(isVolumeGlobal());
}
diff --git a/indra/newview/llflexibleobject.h b/indra/newview/llflexibleobject.h
index beb281a906..a00551df8e 100755
--- a/indra/newview/llflexibleobject.h
+++ b/indra/newview/llflexibleobject.h
@@ -100,7 +100,7 @@ private:
const LLMatrix4& getWorldMatrix(LLXformMatrix* xform) const;
void updateRelativeXform(bool force_identity);
void doFlexibleUpdate(); // Called to update the simulation
- void doFlexibleRebuild(); // Called to rebuild the geometry
+ void doFlexibleRebuild(bool rebuild_volume); // Called to rebuild the geometry
void preRebuild();
//void setAttributes( LLFlexibleObjectData );
diff --git a/indra/newview/llvocache.cpp b/indra/newview/llvocache.cpp
index 6cf6028ae0..2176ec9c9c 100755
--- a/indra/newview/llvocache.cpp
+++ b/indra/newview/llvocache.cpp
@@ -589,13 +589,9 @@ void LLVOCacheEntry::updateParentBoundingInfo(const LLVOCacheEntry* child)
//-------------------------------------------------------------------
LLVOCacheGroup::~LLVOCacheGroup()
{
- for(S32 i = 0; i < LLViewerCamera::NUM_CAMERAS; i++)
+ if(mOcclusionState[LLViewerCamera::CAMERA_WORLD] & ACTIVE_OCCLUSION)
{
- if(mOcclusionState[i] & ACTIVE_OCCLUSION)
- {
- ((LLVOCachePartition*)mSpatialPartition)->removeOccluder(this);
- break;
- }
+ ((LLVOCachePartition*)mSpatialPartition)->removeOccluder(this);
}
}
@@ -979,7 +975,11 @@ void LLVOCachePartition::processOccluders(LLCamera* camera)
group->doOcclusion(camera, &shift);
group->clearOcclusionState(LLOcclusionCullingGroup::ACTIVE_OCCLUSION);
}
- }
+ }
+
+ //safe to clear mOccludedGroups here because only the world camera accesses it.
+ mOccludedGroups.clear();
+ sNeedsOcclusionCheck = FALSE;
}
void LLVOCachePartition::resetOccluders()