summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerstats.h
diff options
context:
space:
mode:
authorChristian Goetze (CG) <cg@lindenlab.com>2010-07-22 13:29:05 -0700
committerChristian Goetze (CG) <cg@lindenlab.com>2010-07-22 13:29:05 -0700
commitfe8a5a007ab82f3d6a763c5cb133e1299d238632 (patch)
tree7a0787f0cb5a70890b878e999521ff4522fd75b4 /indra/newview/llviewerstats.h
parent4339600d43601f07d01c676cce5da17c2758c4cb (diff)
parent9838884d908ad0c910251c64c7cb3c761ac11f70 (diff)
merged from "viewer-hotfix"
Diffstat (limited to 'indra/newview/llviewerstats.h')
-rw-r--r--indra/newview/llviewerstats.h55
1 files changed, 0 insertions, 55 deletions
diff --git a/indra/newview/llviewerstats.h b/indra/newview/llviewerstats.h
index 694eeaf097..13d73000d2 100644
--- a/indra/newview/llviewerstats.h
+++ b/indra/newview/llviewerstats.h
@@ -197,61 +197,6 @@ public:
void addToMessage(LLSD &body) const;
- struct StatsAccumulator
- {
- S32 mCount;
- F32 mSum;
- F32 mSumOfSquares;
- U32 mCountOfNextUpdatesToIgnore;
-
- inline void push( F32 val )
- {
- if ( mCountOfNextUpdatesToIgnore > 0 )
- {
- mCountOfNextUpdatesToIgnore--;
- return;
- }
-
- mCount++;
- mSum += val;
- mSumOfSquares += val * val;
- }
-
- inline F32 getMean() const
- {
- return (mCount == 0) ? 0.f : ((F32)mSum)/mCount;
- }
-
- inline F32 getStdDev() const
- {
- const F32 mean = getMean();
- return (mCount == 0) ? 0.f : sqrt( mSumOfSquares/mCount - (mean * mean) );
- }
-
- inline U32 getCount() const
- {
- return mCount;
- }
-
- inline void reset()
- {
- mCount = 0;
- mSum = mSumOfSquares = 0.f;
- mCountOfNextUpdatesToIgnore = 0;
- }
-
- inline LLSD getData() const
- {
- LLSD data;
- data["mean"] = getMean();
- data["std_dev"] = getStdDev();
- data["count"] = (S32)mCount;
- return data;
- }
- };
-
- StatsAccumulator mAgentPositionSnaps;
-
private:
F64 mStats[ST_COUNT];