summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2010-08-31 21:34:02 -0700
committerMerov Linden <merov@lindenlab.com>2010-08-31 21:34:02 -0700
commit6d8208bac94ca4ebdd8e4e1030cdb8e38ef3da9f (patch)
treec6a21669cc39177e9211507e81c99bfbc0f49be5 /indra/newview
parentbe07498847a4493792ebc943308c3592399d643d (diff)
SNOW-684 VWR-4232 : Some particles don't disappear when UI is hidden
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llhudeffectbeam.cpp5
-rw-r--r--indra/newview/llhudeffectbeam.h1
-rw-r--r--indra/newview/llhudeffecttrail.cpp5
-rw-r--r--indra/newview/llhudeffecttrail.h1
-rw-r--r--indra/newview/llhudobject.cpp21
-rw-r--r--indra/newview/llhudobject.h2
-rw-r--r--indra/newview/pipeline.cpp21
7 files changed, 52 insertions, 4 deletions
diff --git a/indra/newview/llhudeffectbeam.cpp b/indra/newview/llhudeffectbeam.cpp
index 078ccff2d0..37b7b2e75d 100644
--- a/indra/newview/llhudeffectbeam.cpp
+++ b/indra/newview/llhudeffectbeam.cpp
@@ -305,6 +305,11 @@ void LLHUDEffectBeam::render()
}
}
+void LLHUDEffectBeam::renderForTimer()
+{
+ render();
+}
+
void LLHUDEffectBeam::setupParticle(const S32 i)
{
LLVector3d start_pos_global;
diff --git a/indra/newview/llhudeffectbeam.h b/indra/newview/llhudeffectbeam.h
index a700e4e657..fdee5178af 100644
--- a/indra/newview/llhudeffectbeam.h
+++ b/indra/newview/llhudeffectbeam.h
@@ -52,6 +52,7 @@ protected:
~LLHUDEffectBeam();
/*virtual*/ void render();
+ /*virtual*/ void renderForTimer();
/*virtual*/ void packData(LLMessageSystem *mesgsys);
/*virtual*/ void unpackData(LLMessageSystem *mesgsys, S32 blocknum);
private:
diff --git a/indra/newview/llhudeffecttrail.cpp b/indra/newview/llhudeffecttrail.cpp
index 9072707974..39b526c1b5 100644
--- a/indra/newview/llhudeffecttrail.cpp
+++ b/indra/newview/llhudeffecttrail.cpp
@@ -280,3 +280,8 @@ void LLHUDEffectSpiral::render()
return;
}
}
+
+void LLHUDEffectSpiral::renderForTimer()
+{
+ render();
+}
diff --git a/indra/newview/llhudeffecttrail.h b/indra/newview/llhudeffecttrail.h
index bade3ff997..6f5a328c63 100644
--- a/indra/newview/llhudeffecttrail.h
+++ b/indra/newview/llhudeffecttrail.h
@@ -62,6 +62,7 @@ protected:
~LLHUDEffectSpiral();
/*virtual*/ void render();
+ /*virtual*/ void renderForTimer();
/*virtual*/ void packData(LLMessageSystem *mesgsys);
/*virtual*/ void unpackData(LLMessageSystem *mesgsys, S32 blocknum);
private:
diff --git a/indra/newview/llhudobject.cpp b/indra/newview/llhudobject.cpp
index 6af0ae2b6a..3e814a0773 100644
--- a/indra/newview/llhudobject.cpp
+++ b/indra/newview/llhudobject.cpp
@@ -305,6 +305,27 @@ void LLHUDObject::renderAllForSelect()
}
// static
+void LLHUDObject::renderAllForTimer()
+{
+ LLHUDObject *hud_objp;
+
+ hud_object_list_t::iterator object_it;
+ for (object_it = sHUDObjects.begin(); object_it != sHUDObjects.end(); )
+ {
+ hud_object_list_t::iterator cur_it = object_it++;
+ hud_objp = (*cur_it);
+ if (hud_objp->getNumRefs() == 1)
+ {
+ sHUDObjects.erase(cur_it);
+ }
+ else if (hud_objp->isVisible())
+ {
+ hud_objp->renderForTimer();
+ }
+ }
+}
+
+// static
void LLHUDObject::sortObjects()
{
sHUDObjects.sort(hud_object_further_away());
diff --git a/indra/newview/llhudobject.h b/indra/newview/llhudobject.h
index ff70b6a52f..97145b9a84 100644
--- a/indra/newview/llhudobject.h
+++ b/indra/newview/llhudobject.h
@@ -69,6 +69,7 @@ public:
static void updateAll();
static void renderAll();
static void renderAllForSelect();
+ static void renderAllForTimer();
static void cleanupHUDObjects();
@@ -100,6 +101,7 @@ protected:
virtual void render() = 0;
virtual void renderForSelect() {};
+ virtual void renderForTimer() {};
protected:
U8 mType;
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index e4c2ca9ae3..1ee3b84b5e 100644
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -3211,11 +3211,24 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate)
LLVertexBuffer::unbind();
- if (!LLPipeline::sReflectionRender && !LLPipeline::sRenderDeferred && gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI))
+ if (!LLPipeline::sReflectionRender && !LLPipeline::sRenderDeferred)
{
- // Render debugging beacons.
- gObjectList.renderObjectBeacons();
- gObjectList.resetObjectBeacons();
+ if (gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI))
+ {
+ // Render debugging beacons.
+ gObjectList.renderObjectBeacons();
+ gObjectList.resetObjectBeacons();
+ }
+ else
+ {
+ // Make sure particle effects disappear
+ LLHUDObject::renderAllForTimer();
+ }
+ }
+ else
+ {
+ // Make sure particle effects disappear
+ LLHUDObject::renderAllForTimer();
}
LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderGeomEnd");