LLViewerPartSim Class Reference

#include <llviewerpartsim.h>

Inheritance diagram for LLViewerPartSim:

Inheritance graph
[legend]
Collaboration diagram for LLViewerPartSim:

Collaboration graph
[legend]

List of all members.

Public Types

typedef std::vector
< LLViewerPartGroup * > 
group_list_t
typedef std::vector< LLPointer
< LLViewerPartSource > > 
source_list_t

Public Member Functions

 LLViewerPartSim ()
virtual ~LLViewerPartSim ()
void destroyClass ()
void shift (const LLVector3 &offset)
void updateSimulation ()
void addPartSource (LLPointer< LLViewerPartSource > sourcep)
void cleanupRegion (LLViewerRegion *regionp)
BOOL shouldAddPart ()
F32 maxRate ()
F32 getRefRate ()
F32 getBurstRate ()
void addPart (LLViewerPart *part)
void updatePartBurstRate ()
void clearParticlesByID (const U32 system_id)
void clearParticlesByOwnerID (const LLUUID &task_id)
void removeLastCreatedSource ()
const source_list_tgetParticleSystemList () const
BOOL aboveParticleLimit () const

Static Public Member Functions

static void setMaxPartCount (const S32 max_parts)
static S32 getMaxPartCount ()
static void incPartCount (const S32 count)
static void decPartCount (const S32 count)

Public Attributes

U32 mID

Protected Member Functions

LLViewerPartGroupcreateViewerPartGroup (const LLVector3 &pos_agent, const F32 desired_size)
LLViewerPartGroupput (LLViewerPart *part)

Protected Attributes

group_list_t mViewerPartGroups
source_list_t mViewerPartSources
LLFrameTimer mSimulationTimer

Static Protected Attributes

static S32 sMaxParticleCount = 0
static S32 sParticleCount = 0
static F32 sParticleAdaptiveRate = 0.0625f
static F32 sParticleBurstRate = 0.5f
static const S32 MAX_PART_COUNT = 8192
static const F32 PART_THROTTLE_THRESHOLD = 0.9f
static const F32 PART_THROTTLE_RESCALE = PART_THROTTLE_THRESHOLD / (1.0f-PART_THROTTLE_THRESHOLD)
static const F32 PART_ADAPT_RATE_MULT = 2.0f
static const F32 PART_ADAPT_RATE_MULT_RECIP = 1.0f/PART_ADAPT_RATE_MULT

Friends

class LLViewerPartGroup


Detailed Description

Definition at line 128 of file llviewerpartsim.h.


Member Typedef Documentation

Definition at line 135 of file llviewerpartsim.h.

Definition at line 136 of file llviewerpartsim.h.


Constructor & Destructor Documentation

LLViewerPartSim::LLViewerPartSim (  ) 

Definition at line 439 of file llviewerpartsim.cpp.

References LLControlGroup::getS32(), gSavedSettings, mID, LLMemType::MTYPE_PARTICLES, and sMaxParticleCount.

Here is the call graph for this function:

virtual LLViewerPartSim::~LLViewerPartSim (  )  [inline, virtual]

Definition at line 132 of file llviewerpartsim.h.


Member Function Documentation

void LLViewerPartSim::destroyClass (  ) 

Definition at line 448 of file llviewerpartsim.cpp.

References i, LLMemType::MTYPE_PARTICLES, mViewerPartGroups, mViewerPartSources, and S32.

Referenced by LLWorld::destroyClass().

Here is the caller graph for this function:

void LLViewerPartSim::shift ( const LLVector3 offset  ) 

Definition at line 552 of file llviewerpartsim.cpp.

References i, mViewerPartGroups, mViewerPartSources, and S32.

Referenced by LLWorld::shiftRegions().

Here is the caller graph for this function:

void LLViewerPartSim::updateSimulation (  ) 

void LLViewerPartSim::addPartSource ( LLPointer< LLViewerPartSource sourcep  ) 

void LLViewerPartSim::cleanupRegion ( LLViewerRegion regionp  ) 

Definition at line 741 of file llviewerpartsim.cpp.

References i, LLMemType::MTYPE_PARTICLES, and mViewerPartGroups.

Referenced by LLViewerRegion::~LLViewerRegion().

Here is the caller graph for this function:

BOOL LLViewerPartSim::shouldAddPart (  ) 

Definition at line 466 of file llviewerpartsim.cpp.

References FALSE, ll_frand(), MAX_PART_COUNT, LLMemType::MTYPE_PARTICLES, PART_THROTTLE_RESCALE, PART_THROTTLE_THRESHOLD, sMaxParticleCount, sParticleCount, and TRUE.

Here is the call graph for this function:

F32 LLViewerPartSim::maxRate (  )  [inline]

F32 LLViewerPartSim::getRefRate (  )  [inline]

Definition at line 159 of file llviewerpartsim.h.

References sParticleAdaptiveRate.

F32 LLViewerPartSim::getBurstRate (  )  [inline]

Definition at line 160 of file llviewerpartsim.h.

References sParticleBurstRate.

void LLViewerPartSim::addPart ( LLViewerPart part  ) 

Definition at line 489 of file llviewerpartsim.cpp.

References MAX_PART_COUNT, LLMemType::MTYPE_PARTICLES, put(), and sParticleCount.

Referenced by put(), LLViewerPartSourceChat::update(), LLViewerPartSourceBeam::update(), LLViewerPartSourceSpiral::update(), and LLViewerPartSourceScript::update().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLViewerPartSim::updatePartBurstRate (  ) 

Definition at line 693 of file llviewerpartsim.cpp.

References LLDrawable::getCurrentFrame(), llclamp(), llmax(), llmin(), MAX_PART_COUNT, sMaxParticleCount, sParticleBurstRate, and sParticleCount.

Referenced by updateSimulation().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLViewerPartSim::clearParticlesByID ( const U32  system_id  ) 

Definition at line 756 of file llviewerpartsim.cpp.

References i, LLMemType::MTYPE_PARTICLES, mViewerPartGroups, and mViewerPartSources.

Referenced by clearParticlesByOwnerID().

Here is the caller graph for this function:

void LLViewerPartSim::clearParticlesByOwnerID ( const LLUUID task_id  ) 

Definition at line 774 of file llviewerpartsim.cpp.

References clearParticlesByID(), LLMemType::MTYPE_PARTICLES, and mViewerPartSources.

Referenced by LLMuteList::add().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLViewerPartSim::removeLastCreatedSource (  ) 

Definition at line 736 of file llviewerpartsim.cpp.

References mViewerPartSources.

const source_list_t* LLViewerPartSim::getParticleSystemList (  )  const [inline]

Definition at line 167 of file llviewerpartsim.h.

References mViewerPartSources.

BOOL LLViewerPartSim::aboveParticleLimit (  )  const [inline]

Definition at line 171 of file llviewerpartsim.h.

References sMaxParticleCount, and sParticleCount.

static void LLViewerPartSim::setMaxPartCount ( const S32  max_parts  )  [inline, static]

Definition at line 173 of file llviewerpartsim.h.

References sMaxParticleCount.

Referenced by handleMaxPartCountChanged().

Here is the caller graph for this function:

static S32 LLViewerPartSim::getMaxPartCount (  )  [inline, static]

Definition at line 174 of file llviewerpartsim.h.

References sMaxParticleCount.

Referenced by LLVOPartGroup::updateGeometry().

Here is the caller graph for this function:

static void LLViewerPartSim::incPartCount ( const S32  count  )  [inline, static]

Definition at line 175 of file llviewerpartsim.h.

References sParticleCount.

Referenced by LLViewerPartGroup::addPart().

Here is the caller graph for this function:

static void LLViewerPartSim::decPartCount ( const S32  count  )  [inline, static]

Definition at line 176 of file llviewerpartsim.h.

References sParticleCount.

Referenced by LLViewerPartGroup::updateParticles(), and LLViewerPartGroup::~LLViewerPartGroup().

Here is the caller graph for this function:

LLViewerPartGroup * LLViewerPartSim::createViewerPartGroup ( const LLVector3 pos_agent,
const F32  desired_size 
) [protected]

Definition at line 541 of file llviewerpartsim.cpp.

References LLViewerPartGroup, LLMemType::MTYPE_PARTICLES, and mViewerPartGroups.

Referenced by put().

Here is the caller graph for this function:

LLViewerPartGroup * LLViewerPartSim::put ( LLViewerPart part  )  [protected]


Friends And Related Function Documentation

friend class LLViewerPartGroup [friend]

Definition at line 169 of file llviewerpartsim.h.

Referenced by createViewerPartGroup().


Member Data Documentation

Definition at line 178 of file llviewerpartsim.h.

Referenced by LLViewerPartSim(), and updateSimulation().

Definition at line 186 of file llviewerpartsim.h.

S32 LLViewerPartSim::sMaxParticleCount = 0 [static, protected]

S32 LLViewerPartSim::sParticleCount = 0 [static, protected]

F32 LLViewerPartSim::sParticleAdaptiveRate = 0.0625f [static, protected]

Definition at line 190 of file llviewerpartsim.h.

Referenced by getRefRate(), and updateSimulation().

F32 LLViewerPartSim::sParticleBurstRate = 0.5f [static, protected]

Definition at line 191 of file llviewerpartsim.h.

Referenced by getBurstRate(), and updatePartBurstRate().

const S32 LLViewerPartSim::MAX_PART_COUNT = 8192 [static, protected]

Definition at line 193 of file llviewerpartsim.h.

Referenced by addPart(), maxRate(), shouldAddPart(), and updatePartBurstRate().

const F32 LLViewerPartSim::PART_THROTTLE_THRESHOLD = 0.9f [static, protected]

Definition at line 194 of file llviewerpartsim.h.

Referenced by maxRate(), and shouldAddPart().

const F32 LLViewerPartSim::PART_THROTTLE_RESCALE = PART_THROTTLE_THRESHOLD / (1.0f-PART_THROTTLE_THRESHOLD) [static, protected]

Definition at line 195 of file llviewerpartsim.h.

Referenced by maxRate(), and shouldAddPart().

const F32 LLViewerPartSim::PART_ADAPT_RATE_MULT = 2.0f [static, protected]

Definition at line 196 of file llviewerpartsim.h.

Referenced by updateSimulation().

const F32 LLViewerPartSim::PART_ADAPT_RATE_MULT_RECIP = 1.0f/PART_ADAPT_RATE_MULT [static, protected]

Definition at line 197 of file llviewerpartsim.h.

Referenced by updateSimulation().


The documentation for this class was generated from the following files:

Generated on Fri May 16 09:32:48 2008 for SecondLife by  doxygen 1.5.5