summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llviewerobjectlist.cpp15
-rw-r--r--indra/newview/llviewerobjectlist.h1
-rwxr-xr-xindra/newview/llviewerwindow.cpp3
3 files changed, 13 insertions, 6 deletions
diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp
index e399b45cba..9e5c3f14f8 100644
--- a/indra/newview/llviewerobjectlist.cpp
+++ b/indra/newview/llviewerobjectlist.cpp
@@ -948,7 +948,7 @@ void LLViewerObjectList::update(LLAgent &agent, LLWorld &world)
std::vector<LLViewerObject*>::iterator idle_end = idle_list.begin()+idle_count;
if (gSavedSettings.getBOOL("FreezeTime"))
- {
+ {
for (std::vector<LLViewerObject*>::iterator iter = idle_list.begin();
iter != idle_end; iter++)
@@ -969,14 +969,14 @@ void LLViewerObjectList::update(LLAgent &agent, LLWorld &world)
llassert(objectp->isActive());
objectp->idleUpdate(agent, world, frame_time);
- }
+ }
//update flexible objects
LLVolumeImplFlexible::updateClass();
//update animated textures
LLViewerTextureAnim::updateClass();
- }
+ }
@@ -1401,9 +1401,9 @@ void LLViewerObjectList::removeFromActiveList(LLViewerObject* objectp)
mActiveObjects[idx]->setListIndex(idx);
}
- mActiveObjects.pop_back();
+ mActiveObjects.pop_back();
+ }
}
-}
void LLViewerObjectList::updateActive(LLViewerObject *objectp)
{
@@ -1446,8 +1446,11 @@ void LLViewerObjectList::updateActive(LLViewerObject *objectp)
}
}
- llassert(objectp->isActive() || objectp->getListIndex() == -1);
+ //post condition: if object is active, it must be on the active list
+ llassert(!active || std::find(mActiveObjects.begin(), mActiveObjects.end(), objectp) != mActiveObjects.end());
+ //post condition: if object is not active, it must not be on the active list
+ llassert(active || std::find(mActiveObjects.begin(), mActiveObjects.end(), objectp) == mActiveObjects.end());
}
void LLViewerObjectList::updateObjectCost(LLViewerObject* object)
diff --git a/indra/newview/llviewerobjectlist.h b/indra/newview/llviewerobjectlist.h
index 9936432a71..449a4633ff 100644
--- a/indra/newview/llviewerobjectlist.h
+++ b/indra/newview/llviewerobjectlist.h
@@ -129,6 +129,7 @@ public:
LLViewerObject *getSelectedObject(const U32 object_id);
inline S32 getNumObjects() { return (S32) mObjects.size(); }
+ inline S32 getNumActiveObjects() { return (S32) mActiveObjects.size(); }
void addToMap(LLViewerObject *objectp);
void removeFromMap(LLViewerObject *objectp);
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index 4e37a9043d..3b2292c04d 100755
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -563,6 +563,9 @@ public:
addText(xpos, ypos, llformat("%d Render Calls", gPipeline.mBatchCount));
ypos += y_inc;
+ addText(xpos, ypos, llformat("%d/%d Objects Active", gObjectList.getNumActiveObjects(), gObjectList.getNumObjects()));
+ ypos += y_inc;
+
addText(xpos, ypos, llformat("%d Matrix Ops", gPipeline.mMatrixOpCount));
ypos += y_inc;