Class TParticleSystemSceneNode

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TParticleSystemSceneNode = class(TSceneNode)

Description

A particle system scene node for creating snow, fire, exlosions, smoke...
A scene node controlling a particle System. The behavior of the particles can be controlled by setting the right particle emitters and affectors. You can for example easily create a campfire by doing this:

    var P: TParticleSystemSceneNode;
        Em: TParticleEmitter;
        Paf: TParticleAffector;
    ...
    P := SceneManager.AddParticleSystemSceneNode;
    P.ParticleSize := Dimension(20.0f, 10.0f);
    Em := P.CreateBoxEmitter(BoundingBox(-5,0,-5,5,1,5), Vector3D(0.0f,0.03f,0.0f),
            40, 80, ARGBColor(0,255,255,255),video::SColor(0,255,255,255), 1100,2000);
    P.SetEmitter(Em);
    Em.Drop;
    Paf := P.CreateFadeOutParticleAffector;
    P.AddAffector(Paf);
    Paf.Drop();
        

Hierarchy

Overview

Methods

Public function CreateAnimatedMeshSceneNodeEmitter(Node: TAnimatedMeshSceneNode; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single = 100; Number: Integer = -1; EveryMeshVertex: Boolean = False; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleAnimatedMeshSceneNodeEmitter; overload; inline;
Public function CreateAnimatedMeshSceneNodeEmitter(Node: TAnimatedMeshSceneNode; UseNormalDirection: Boolean = True): TParticleAnimatedMeshSceneNodeEmitter; overload; inline;
Public function CreateAnimatedMeshSceneNodeEmitter(Node: TAnimatedMeshSceneNode; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single; Number: Integer; EveryMeshVertex: Boolean; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleAnimatedMeshSceneNodeEmitter; overload; inline;
Public function CreateAttractionAffector(const Point: TVector3D; Speed: Single = 1; Attract: Boolean = True; AffectX: Boolean = True; AffectY: Boolean = True; AffectZ: Boolean = True): TParticleAttractionAffector; inline;
Public function CreateBoxEmitter(const Box: TBoundingBox; const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleBoxEmitter; overload; inline;
Public function CreateBoxEmitter(const Box: TBoundingBox): TParticleBoxEmitter; overload; inline;
Public function CreateBoxEmitter(const Box: TBoundingBox; const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleBoxEmitter; overload; inline;
Public function CreateCylinderEmitter(const Center: TVector3D; Radius: Single; const Normal: TVector3D; Length: Single; OutlineOnly: Boolean; const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleCylinderEmitter; overload; inline;
Public function CreateCylinderEmitter(const Center: TVector3D; Radius: Single; const Normal: TVector3D; Length: Single; OutlineOnly: Boolean = False): TParticleCylinderEmitter; overload; inline;
Public function CreateCylinderEmitter(const Center: TVector3D; Radius: Single; const Normal: TVector3D; Length: Single; OutlineOnly: Boolean; const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleCylinderEmitter; overload; inline;
Public function CreateFadeOutAffector(TargetColor: TARGBColor = $00000000; TimeToFadeOut: LongWord = 1000): TParticleFadeOutAffector; inline;
Public function CreateGravityAffector: TParticleGravityAffector; overload; inline;
Public function CreateGravityAffector(const Gravity: TVector3D; TimeForceLost: LongWord = 1000): TParticleGravityAffector; overload; inline;
Public function CreateMeshEmitter(Mesh: TMesh; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single = 100; Number: Integer = -1; EveryMeshVertex: Boolean = False; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleMeshEmitter; overload; inline;
Public function CreateMeshEmitter(Mesh: TMesh; UseNormalDirection: Boolean = True): TParticleMeshEmitter; overload; inline;
Public function CreateMeshEmitter(Mesh: TMesh; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single; Number: Integer; EveryMeshVertex: Boolean; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleMeshEmitter; overload; inline;
Public function CreatePointEmitter(const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleEmitter; overload; inline;
Public function CreatePointEmitter: TParticleEmitter; overload; inline;
Public function CreatePointEmitter(const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleEmitter; overload; inline;
Public function CreateRingEmitter(const Center: TVector3D; Radius: Single; RingThickness: Single; const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleRingEmitter; overload; inline;
Public function CreateRingEmitter(const Center: TVector3D; Radius: Single; RingThickness: Single): TParticleRingEmitter; overload; inline;
Public function CreateRingEmitter(const Center: TVector3D; Radius: Single; RingThickness: Single; const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleRingEmitter; overload; inline;
Public function CreateRotationAffector(const Speed: TVector3D): TParticleRotationAffector; overload; inline;
Public function CreateRotationAffector: TParticleRotationAffector; overload; inline;
Public function CreateRotationAffector(const Speed: TVector3D; const PivotPoint: TVector3D): TParticleRotationAffector; overload; inline;
Public function CreateScaleParticleAffector: TParticleAffector; overload; inline;
Public function CreateScaleParticleAffector(const ScaleTo: TDimension): TParticleAffector; overload; inline;
Public function CreateSphereEmitter(const Center: TVector3D; Radius: Single; const Direction: TVector3D; NormalDirectionModifier: Single = 100; Number: Integer = -1; EveryMeshVertex: Boolean = False; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleSphereEmitter; overload; inline;
Public function CreateSphereEmitter(const Center: TVector3D; Radius: Single): TParticleSphereEmitter; overload; inline;
Public function CreateSphereEmitter(const Center: TVector3D; Radius: Single; const Direction: TVector3D; NormalDirectionModifier: Single; Number: Integer; EveryMeshVertex: Boolean; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleSphereEmitter; overload; inline;
Public function GetEmitter: TParticleEmitter; inline;
Public procedure AddAffector(Affector: TParticleAffector); inline;
Public procedure RemoveAllAffectors; inline;
Public procedure SetEmitter(Emitter: TParticleEmitter); inline;
Public procedure SetParticlesAreGlobal(Global: Boolean = True); inline;
Public procedure SetParticleSize(const Size: TDimension); inline;

Description

Methods

Public function CreateAnimatedMeshSceneNodeEmitter(Node: TAnimatedMeshSceneNode; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single = 100; Number: Integer = -1; EveryMeshVertex: Boolean = False; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleAnimatedMeshSceneNodeEmitter; overload; inline;

Creates a particle emitter for an animated mesh scene node.
Overloaded for default parameters. . @þaram MaxParticlesPerSecond Maximal amount of particles emitted per second.

Parameters
Node
The animated mesh scene node to emit particles from.
UseNormalDirection
If true, the direction of each particle created will be the normal of the vertex that it's emitting from. The normal is divided by the normalDirectionModifier parameter, which defaults to 100
Direction
Direction and speed of particle emission.
NormalDirectionModifier
If the emitter is using the normal direction then the normal of the vertex that is being emitted from is divided by this number.
Number
This allows you to specify a specific meshBuffer for the TMesh to emit particles from. The default value is -1, which means a random meshBuffer picked from all of the meshes meshBuffers will be selected to pick a random vertex from. If the value is 0 or greater, it will only pick random vertices from the meshBuffer specified by this value.
EveryMeshVertex
If true, the emitter will emit between min/max particles every second, for every vertex in the mesh, if false, it will emit between min/max particles from random vertices in the mesh.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between MinStartColor and MaxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and MaxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop() for more information.

Public function CreateAnimatedMeshSceneNodeEmitter(Node: TAnimatedMeshSceneNode; UseNormalDirection: Boolean = True): TParticleAnimatedMeshSceneNodeEmitter; overload; inline;

Creates a particle emitter for an animated mesh scene node.
Overloaded for default parameters. .

Parameters
Node
The animated mesh scene node to emit particles from.
UseNormalDirection
If true, the direction of each particle created will be the normal of the vertex that it's emitting from. The normal is divided by the normalDirectionModifier parameter, which defaults to 100
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop() for more information.

Public function CreateAnimatedMeshSceneNodeEmitter(Node: TAnimatedMeshSceneNode; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single; Number: Integer; EveryMeshVertex: Boolean; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleAnimatedMeshSceneNodeEmitter; overload; inline;

Creates a particle emitter for an animated mesh scene node. . @þaram MaxParticlesPerSecond Maximal amount of particles emitted per second.

Parameters
Node
The animated mesh scene node to emit particles from.
UseNormalDirection
If true, the direction of each particle created will be the normal of the vertex that it's emitting from. The normal is divided by the normalDirectionModifier parameter, which defaults to 100
Direction
Direction and speed of particle emission.
NormalDirectionModifier
If the emitter is using the normal direction then the normal of the vertex that is being emitted from is divided by this number.
Number
This allows you to specify a specific meshBuffer for the TMesh to emit particles from. The default value is -1, which means a random meshBuffer picked from all of the meshes meshBuffers will be selected to pick a random vertex from. If the value is 0 or greater, it will only pick random vertices from the meshBuffer specified by this value.
EveryMeshVertex
If true, the emitter will emit between min/max particles every second, for every vertex in the mesh, if false, it will emit between min/max particles from random vertices in the mesh.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between MinStartColor and MaxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and MaxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
MinStartSize
Minimal initial start size of a particle. The real size of every particle is calculated as random interpolation between MinStartSize and MaxStartSize.
MaxStartSize
Maximal initial start size of a particle. The real size of every particle is calculated as random interpolation between MinStartSize and MaxStartSize .
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop() for more information.

Public function CreateAttractionAffector(const Point: TVector3D; Speed: Single = 1; Attract: Boolean = True; AffectX: Boolean = True; AffectY: Boolean = True; AffectZ: Boolean = True): TParticleAttractionAffector; inline;

Creates a point attraction affector.
This affector modifies the positions of the particles and attracts them to a specified point at a specified speed per second.

Parameters
Point
to attract particles to.
Speed
Speed in units per second, to attract to the specified point.
Attract
Whether the particles attract or detract from this point.
AffectX
Whether or not this will affect the X position of the particle.
AffectY
Whether or not this will affect the Y position of the particle.
AffectZ
Whether or not this will affect the Z position of the particle.
Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateBoxEmitter(const Box: TBoundingBox; const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleBoxEmitter; overload; inline;

Creates a box particle emitter.
Overloaded for default parameters.

Parameters
Box
The box for the emitter.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop() for more information.

Public function CreateBoxEmitter(const Box: TBoundingBox): TParticleBoxEmitter; overload; inline;

Creates a box particle emitter.
Overloaded for default parameters.

Parameters
Box
The box for the emitter.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop() for more information.

Public function CreateBoxEmitter(const Box: TBoundingBox; const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleBoxEmitter; overload; inline;

Creates a box particle emitter.

Parameters
Box
The box for the emitter.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
MinStartSize
Minimal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
MaxStartSize
Maximal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop() for more information.

Public function CreateCylinderEmitter(const Center: TVector3D; Radius: Single; const Normal: TVector3D; Length: Single; OutlineOnly: Boolean; const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleCylinderEmitter; overload; inline;

Creates a particle emitter for emitting from a cylinder.
Overloaded for default parameters.

Parameters
Center
The center of the circle at the base of the cylinder.
Radius
The thickness of the cylinder.
Normal
Direction of the length of the cylinder.
Length
The length of the the cylinder.
OutlineOnly
Whether or not to put points inside the cylinder or on the outline only.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateCylinderEmitter(const Center: TVector3D; Radius: Single; const Normal: TVector3D; Length: Single; OutlineOnly: Boolean = False): TParticleCylinderEmitter; overload; inline;

Creates a particle emitter for emitting from a cylinder.
Overloaded for default parameters.

Parameters
Center
The center of the circle at the base of the cylinder.
Radius
The thickness of the cylinder.
Normal
Direction of the length of the cylinder.
Length
The length of the the cylinder.
OutlineOnly
Whether or not to put points inside the cylinder or on the outline only.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateCylinderEmitter(const Center: TVector3D; Radius: Single; const Normal: TVector3D; Length: Single; OutlineOnly: Boolean; const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleCylinderEmitter; overload; inline;

Creates a particle emitter for emitting from a cylinder.

Parameters
Center
The center of the circle at the base of the cylinder.
Radius
The thickness of the cylinder.
Normal
Direction of the length of the cylinder.
Length
The length of the the cylinder.
OutlineOnly
Whether or not to put points inside the cylinder or on the outline only.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
MinStartSize
Minimal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
MaxStartSize
Maximal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateFadeOutAffector(TargetColor: TARGBColor = $00000000; TimeToFadeOut: LongWord = 1000): TParticleFadeOutAffector; inline;

Creates a fade out particle affector.
This affector modifies the color of every particle and and reaches the final color when the particle dies. This affector looks really good, if the mtTransparentVertexAlpha material is used and the targetColor is ARGBColor(0,0,0,0): Particles are fading out into void with this setting.

Parameters
TargetColor
Color whereto the color of the particle is changed.
TimeNeededToFadeOut
How much time in milliseconds should the affector need to change the color to the targetColor.
Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateGravityAffector: TParticleGravityAffector; overload; inline;

Creates a gravity affector.
Overloaded for default parameters.
This affector modifies the direction of the particle. It assumes that the particle is fired out of the emitter with huge force, but is loosing this after some time and is catched by the gravity then. This affector is ideal for creating things like fountains.

Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateGravityAffector(const Gravity: TVector3D; TimeForceLost: LongWord = 1000): TParticleGravityAffector; overload; inline;

Creates a gravity affector.
This affector modifies the direction of the particle. It assumes that the particle is fired out of the emitter with huge force, but is loosing this after some time and is catched by the gravity then. This affector is ideal for creating things like fountains.

Parameters
Gravity
Direction and force of gravity.
TimeForceLost
Time in milli seconds when the force of the emitter is totally lost and the particle does not move any more. This is the time where gravity fully affects the particle.
Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateMeshEmitter(Mesh: TMesh; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single = 100; Number: Integer = -1; EveryMeshVertex: Boolean = False; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleMeshEmitter; overload; inline;

Creates a mesh particle emitter.
Overloaded for default parameters.

Parameters
Mesh
Pointer to mesh to emit particles from
UseNormalDirection
If true, the direction of each particle created will be the normal of the vertex that it's emitting from. The normal is divided by the normalDirectionModifier parameter, which defaults to 100.
Direction
Direction and speed of particle emission.
NormalDirectionModifier
If the emitter is using the normal direction then the normal of the vertex that is being emitted from is divided by this number.
Number
This allows you to specify a specific meshBuffer for the TMesh to emit particles from. The default value is -1, which means a random meshBuffer picked from all of the meshes meshBuffers will be selected to pick a random vertex from. If the value is 0 or greater, it will only pick random vertices from the meshBuffer specified by this value.
EveryMeshVertex
If true, the emitter will emit between min/max particles every second, for every vertex in the mesh, if false, it will emit between min/max particles from random vertices in the mesh.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateMeshEmitter(Mesh: TMesh; UseNormalDirection: Boolean = True): TParticleMeshEmitter; overload; inline;

Creates a mesh particle emitter.
Overloaded for default parameters.

Parameters
Mesh
Pointer to mesh to emit particles from
UseNormalDirection
If true, the direction of each particle created will be the normal of the vertex that it's emitting from. The normal is divided by the normalDirectionModifier parameter, which defaults to 100.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateMeshEmitter(Mesh: TMesh; UseNormalDirection: Boolean; const Direction: TVector3D; NormalDirectionModifier: Single; Number: Integer; EveryMeshVertex: Boolean; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleMeshEmitter; overload; inline;

Creates a mesh particle emitter.

Parameters
Mesh
Pointer to mesh to emit particles from
UseNormalDirection
If true, the direction of each particle created will be the normal of the vertex that it's emitting from. The normal is divided by the normalDirectionModifier parameter, which defaults to 100.
Direction
Direction and speed of particle emission.
NormalDirectionModifier
If the emitter is using the normal direction then the normal of the vertex that is being emitted from is divided by this number.
Number
This allows you to specify a specific meshBuffer for the TMesh to emit particles from. The default value is -1, which means a random meshBuffer picked from all of the meshes meshBuffers will be selected to pick a random vertex from. If the value is 0 or greater, it will only pick random vertices from the meshBuffer specified by this value.
EveryMeshVertex
If true, the emitter will emit between min/max particles every second, for every vertex in the mesh, if false, it will emit between min/max particles from random vertices in the mesh.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
MinStartSize
Minimal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
MaxStartSize
Maximal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreatePointEmitter(const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleEmitter; overload; inline;

Creates a point particle emitter.
Overloaded for default parameters.

Parameters
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreatePointEmitter: TParticleEmitter; overload; inline;

Creates a point particle emitter.
Overloaded for default parameters.

Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreatePointEmitter(const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleEmitter; overload; inline;

Creates a point particle emitter.

Parameters
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
MinStartSize
Minimal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
MaxStartSize
Maximal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateRingEmitter(const Center: TVector3D; Radius: Single; RingThickness: Single; const Direction: TVector3D; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleRingEmitter; overload; inline;

Creates a ring particle emitter.
Overloaded for default parameters.

Parameters
Center
Center of ring
Radius
Distance of points from center, points will be rotated around the Y axis at a random 360 degrees and will then be shifted by the provided ringThickness values in each axis.
RingThickness
Thickness of the ring or how wide the ring is.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateRingEmitter(const Center: TVector3D; Radius: Single; RingThickness: Single): TParticleRingEmitter; overload; inline;

Creates a ring particle emitter.
Overloaded for default parameters.

Parameters
Center
Center of ring
Radius
Distance of points from center, points will be rotated around the Y axis at a random 360 degrees and will then be shifted by the provided ringThickness values in each axis.
RingThickness
Thickness of the ring or how wide the ring is.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateRingEmitter(const Center: TVector3D; Radius: Single; RingThickness: Single; const Direction: TVector3D; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleRingEmitter; overload; inline;

Creates a ring particle emitter.

Parameters
Center
Center of ring
Radius
Distance of points from center, points will be rotated around the Y axis at a random 360 degrees and will then be shifted by the provided ringThickness values in each axis.
RingThickness
Thickness of the ring or how wide the ring is.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
MinStartSize
Minimal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
MaxStartSize
Maximal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateRotationAffector(const Speed: TVector3D): TParticleRotationAffector; overload; inline;

Creates a rotation affector.
Overloaded for default parameters.
This affector modifies the positions of the particles and attracts them to a specified point at a specified speed per second.

Parameters
Speed
Rotation in degrees per second.
Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateRotationAffector: TParticleRotationAffector; overload; inline;

Creates a rotation affector.
Overloaded for default parameters.
This affector modifies the positions of the particles and attracts them to a specified point at a specified speed per second.

Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateRotationAffector(const Speed: TVector3D; const PivotPoint: TVector3D): TParticleRotationAffector; overload; inline;

Creates a rotation affector.
This affector modifies the positions of the particles and attracts them to a specified point at a specified speed per second.

Parameters
Speed
Rotation in degrees per second.
PivotPoint
Point to rotate the particles around.
Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateScaleParticleAffector: TParticleAffector; overload; inline;

Creates a scale particle affector.
Overloaded for default parameters.
This affector scales the particle to the a multiple of its size defined by the scaleTo variable.

Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateScaleParticleAffector(const ScaleTo: TDimension): TParticleAffector; overload; inline;

Creates a scale particle affector.
This affector scales the particle to the a multiple of its size defined by the scaleTo variable.

Parameters
ScaleTo
Multiple of the size which the particle will be scaled to until deletion.
Returns

The created particle affector. To add this affector as new affector of this particle system, just call AddAffector. Note that you'll have to Drop the returned reference, after you don't need it any more, see TReferenceCounted.Drop for more information.

Public function CreateSphereEmitter(const Center: TVector3D; Radius: Single; const Direction: TVector3D; NormalDirectionModifier: Single = 100; Number: Integer = -1; EveryMeshVertex: Boolean = False; MinParticlesPerSecond: LongWord = 5; MaxParticlesPerSecond: LongWord = 10; MinStartColor: TARGBColor = $ff000000; MaxStartColor: TARGBColor = $ffffffff; LifeTimeMin: LongWord = 2000; LifeTimeMax: LongWord = 4000; MaxAngleDegrees: LongInt = 0): TParticleSphereEmitter; overload; inline;

Creates a sphere particle emitter.
Overloaded for default parameters.

Parameters
Center
Center of sphere.
Radius
Radius of sphere.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateSphereEmitter(const Center: TVector3D; Radius: Single): TParticleSphereEmitter; overload; inline;

Creates a sphere particle emitter.
Overloaded for default parameters.

Parameters
Center
Center of sphere.
Radius
Radius of sphere.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function CreateSphereEmitter(const Center: TVector3D; Radius: Single; const Direction: TVector3D; NormalDirectionModifier: Single; Number: Integer; EveryMeshVertex: Boolean; MinParticlesPerSecond: LongWord; MaxParticlesPerSecond: LongWord; MinStartColor: TARGBColor; MaxStartColor: TARGBColor; LifeTimeMin: LongWord; LifeTimeMax: LongWord; MaxAngleDegrees: LongInt; MinStartSize: TDimension; MaxStartSize: TDimension): TParticleSphereEmitter; overload; inline;

Creates a sphere particle emitter.

Parameters
Center
Center of sphere.
Radius
Radius of sphere.
Direction
Direction and speed of particle emission.
MinParticlesPerSecond
Minimal amount of particles emitted per second.
MaxParticlesPerSecond
Maximal amount of particles emitted per second.
MinStartColor
Minimal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
MaxStartColor
Maximal initial start color of a particle. The real color of every particle is calculated as random interpolation between minStartColor and maxStartColor.
LifeTimeMin
Minimal lifetime of a particle, in milliseconds.
LifeTimeMax
Maximal lifetime of a particle, in milliseconds.
MaxAngleDegrees
Maximal angle in degrees, the emitting direction of the particle will differ from the original direction.
MinStartSize
Minimal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
MaxStartSize
Maximal initial start size of a particle. The real size of every particle is calculated as random interpolation between minStartSize and maxStartSize.
Returns

The created particle emitter. To set this emitter as new emitter of this particle system, just call SetEmitter(). Note that you'll have to Drop() the returned pointer, after you don't need it any more, see TReferenceCounted.Drop() for more informations.

Public function GetEmitter: TParticleEmitter; inline;

Gets the particle emitter, which creates the particles.

Returns

The emitter or nil if none is set.

Public procedure AddAffector(Affector: TParticleAffector); inline;

Adds new particle effector to the particle system.
A particle affector modifies the particles. For example, the FadeOut affector lets all particles fade out after some time. It is created and used in this way:

    var P: TParticleAffector;
    ...
    P := Node.CreateFadeOutParticleAffector;
    Node.AddAffector(P);
    P.Drop();
                

Please note that an affector is not necessary for the particle system to work.

Parameters
Affector
New affector.
Public procedure RemoveAllAffectors; inline;

Removes all particle affectors in the particle system.

Public procedure SetEmitter(Emitter: TParticleEmitter); inline;

Sets the particle emitter, which creates the particles.
A particle emitter can be created using one of the createEmitter methods. For example to create and use a simple PointEmitter, call

    P := Node.CeatePointEmitter; 
    Node.SetEmitter(P); 
    P.Drop;
                

Parameters
Emitter
Sets the particle emitter. You can set this to nil for removing the current emitter and stopping the particle system emitting new particles.
Public procedure SetParticlesAreGlobal(Global: Boolean = True); inline;

Sets if the particles should be global.
If they are, the particles are affected by the movement of the particle system scene node too, otherwise they completely ignore it. Default is true.

Public procedure SetParticleSize(const Size: TDimension); inline;

Sets the size of all particles.


Generated by PasDoc 0.12.1 on 2012-09-14 17:32:22