3ds Max C++ API Reference
IPFSystem.h

Enumerations

enum  {
  kEmitterType_none = -1 , kEmitterType_rectangle = 0 , kEmitterType_circle , kEmitterType_box ,
  kEmitterType_sphere , kEmitterType_mesh
}
 
enum  { kPFUpdateType_complete , kPFUpdateType_forward }
 

Functions

virtual float GetMultiplier (TimeValue time)=0
 Returns multiplier coefficient to generate particles. More...
 
virtual int GetBornAllowance ()=0
 Returns number of particles allowed to be generated at current time. More...
 
virtual bool HasEmitter ()
 PF System has an icon that can be used as an emitter for particles. More...
 
virtual int GetEmitterType (TimeValue time)
 
virtual void GetEmitterDimensions (TimeValue time, Tab< float > &dimensions)
 Returns spacial dimensions of the emitter icon. More...
 
virtual MeshGetEmitterGeometry (TimeValue time)
 Returns emitter geometry in form of mesh. More...
 
virtual bool IsEmitterGeometryAnimated ()
 If the emitter mesh is geometry-animated, return "true" in the following method. More...
 
virtual void SetRenderState (bool renderState=true)=0
 PF System has two states: render and viewport. More...
 
virtual bool IsRenderState () const =0
 Works with SetRenderState. More...
 
virtual TimeValue GetIntegrationStep () const =0
 PF System has an integration step parameter that defines granularity in proceeding particles in time. More...
 
virtual int GetUpdateType () const
 PF system has different modes for update. More...
 
virtual int NumParticlesSelected () const
 PF system may select sub-components. More...
 
virtual int GetSelectedParticleID (int i) const
 Returns born ID of the i-th selected particle. More...
 
virtual bool IsParticleSelected (int id) const
 Verifies if a particle with the given born ID is selected or not. More...
 
virtual int NumActionListsSelected () const
 Returns amount of selected action lists. More...
 
virtual INodeGetSelectedActionList (int i) const
 Returns node of the i-th selected action list. More...
 
virtual bool IsActionListSelected (INode *inode) const
 Verifies if an action list is selected or not. More...
 
virtual bool IsRunningScript () const
 Returns true if the particle system is in the process of runnint Every Step or Final Step scripts. More...
 
virtual bool IsCopyClone () const
 For internal use. More...
 
virtual void ResetCopyClone ()
 Works with IsCopyClone. More...
 
FPInterfaceDescGetDesc ()
 

Detailed Description

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
kEmitterType_none 
kEmitterType_rectangle 
kEmitterType_circle 
kEmitterType_box 
kEmitterType_sphere 
kEmitterType_mesh 
111  { kEmitterType_none = -1,
117  };
@ kEmitterType_rectangle
Definition: IPFSystem.h:112
@ kEmitterType_mesh
Definition: IPFSystem.h:116
@ kEmitterType_box
Definition: IPFSystem.h:114
@ kEmitterType_none
Definition: IPFSystem.h:111
@ kEmitterType_sphere
Definition: IPFSystem.h:115
@ kEmitterType_circle
Definition: IPFSystem.h:113

◆ anonymous enum

anonymous enum
Enumerator
kPFUpdateType_complete 
kPFUpdateType_forward 
@ kPFUpdateType_forward
Definition: IPFSystem.h:169
@ kPFUpdateType_complete
Definition: IPFSystem.h:169

Function Documentation

◆ GetMultiplier()

float GetMultiplier ( TimeValue  time)
pure virtual

Returns multiplier coefficient to generate particles.

Value 1.0f means that an operator produces particles at 100% rate. Value 0.5f means that an operator produces only half of particles that it supposed to be generating, i.e. if a Birth operator is set to produce 1000 particles total, then under multiplier = 0.5f the operator produces only 500 particles.

◆ GetBornAllowance()

int GetBornAllowance ( )
pure virtual

Returns number of particles allowed to be generated at current time.

Particle system has an upper limit of a total number of particles in the system. At each moment of time particle system is able to calculate the current number of particle in the system and how many particles are allowed to be generated to not exceed the limit threshold. Birth and Spawn Operators use this method to find out how many particles they are allowed to generate.

◆ HasEmitter()

bool HasEmitter ( )
inlinevirtual

PF System has an icon that can be used as an emitter for particles.

For Operators to use the icon as an emitter the following five methods should be supported. If PF System doesn't support emitter icon then it returns "false" in the first method. The default implementation of the following five methods is if PF System doesn't support icon emission.

109 { return false; }

◆ GetEmitterType()

int GetEmitterType ( TimeValue  time)
inlinevirtual
123 { return kEmitterType_none; }

◆ GetEmitterDimensions()

void GetEmitterDimensions ( TimeValue  time,
Tab< float > &  dimensions 
)
inlinevirtual

Returns spacial dimensions of the emitter icon.

It may have less or more than three as emitter type requires. For example, sphere emitter type has only one dimension.

129 { }

◆ GetEmitterGeometry()

Mesh * GetEmitterGeometry ( TimeValue  time)
inlinevirtual

Returns emitter geometry in form of mesh.

134 { return NULL; }
#define NULL
Definition: autoptr.h:18

◆ IsEmitterGeometryAnimated()

bool IsEmitterGeometryAnimated ( )
inlinevirtual

If the emitter mesh is geometry-animated, return "true" in the following method.

139 { return false; }

◆ SetRenderState()

void SetRenderState ( bool  renderState = true)
pure virtual

PF System has two states: render and viewport.

At any given moment PF System is exclusively in one state or the other. PF System may have different parameters during render and viewport (i.e. Multiplier value, or emitter geometry etc.) therefore it's important to know what state the PF System is in. It's also possible to alterate the state of PF System. PF System alterates its state automatically when the rendering starts and when the rendering ends.

◆ IsRenderState()

bool IsRenderState ( ) const
pure virtual

Works with SetRenderState.

◆ GetIntegrationStep()

TimeValue GetIntegrationStep ( ) const
pure virtual

PF System has an integration step parameter that defines granularity in proceeding particles in time.

An PF System may have different integration steps for viewports and for render.

◆ GetUpdateType()

int GetUpdateType ( ) const
inlinevirtual

PF system has different modes for update.

Forward mode: particles aren't updated right away. At playback time the particle history is not recalculated. Only new events that will happen with the particles have new settings Complete mode: the whole particle animation is recalculated.

170 { return GetPFUpdateType(); } // uses global UpdateType method from IPViewManager
PFExport int GetPFUpdateType()

◆ NumParticlesSelected()

int NumParticlesSelected ( ) const
inlinevirtual

PF system may select sub-components.

There are two types of sub-components: particles and action lists. Returns amount of selected particles.

176 { return 0; }

◆ GetSelectedParticleID()

int GetSelectedParticleID ( int  i) const
inlinevirtual

Returns born ID of the i-th selected particle.

181 { return 0; }

◆ IsParticleSelected()

bool IsParticleSelected ( int  id) const
inlinevirtual

Verifies if a particle with the given born ID is selected or not.

186 { return false; }

◆ NumActionListsSelected()

int NumActionListsSelected ( ) const
inlinevirtual

Returns amount of selected action lists.

191 { return 0; }

◆ GetSelectedActionList()

INode * GetSelectedActionList ( int  i) const
inlinevirtual

Returns node of the i-th selected action list.

196 { return NULL; }

◆ IsActionListSelected()

bool IsActionListSelected ( INode inode) const
inlinevirtual

Verifies if an action list is selected or not.

201 { return false; }

◆ IsRunningScript()

bool IsRunningScript ( ) const
inlinevirtual

Returns true if the particle system is in the process of runnint Every Step or Final Step scripts.

206 { return false; }

◆ IsCopyClone()

bool IsCopyClone ( ) const
inlinevirtual

For internal use.

211 { return true; }

◆ ResetCopyClone()

void ResetCopyClone ( )
inlinevirtual

Works with IsCopyClone.

216 { ; }

◆ GetDesc()

FPInterfaceDesc * GetDesc ( )
inlinevirtual
Remarks
Returns a pointer to the class which contains the interface metadata.

Implements FPInterface.

221 { return GetDescByID(PFSYSTEM_INTERFACE); }
#define PFSYSTEM_INTERFACE
Definition: IPFSystem.h:25
virtual FPInterfaceDesc * GetDescByID(Interface_ID id)
Definition: ifnpub.h:613