Class ParticlesEmitter
Class that represents one particle system emitter.
Inherited Members
Namespace: Evergine.Framework.Particles.Asset
Assembly: Evergine.Framework.dll
Syntax
public class ParticlesEmitter : IdentifiableObject
  Constructors
ParticlesEmitter(ParticleEmitterDescription, GraphicsContext, AssetsService)
Initializes a new instance of the ParticlesEmitter class.
Declaration
public ParticlesEmitter(ParticleEmitterDescription description, GraphicsContext graphicsContext, AssetsService assetsService)
  Parameters
| Type | Name | Description | 
|---|---|---|
| ParticleEmitterDescription | description | The emitter description.  | 
      
| GraphicsContext | graphicsContext | The graphics context.  | 
      
| AssetsService | assetsService | The assets service.  | 
      
Fields
ColorCurveArray
The array with the values of the color over life curve.
Declaration
public Vector4[] ColorCurveArray
  Field Value
| Type | Description | 
|---|---|
| Vector4[] | 
ColorOverLifeTexture
The texture that represents the color over life.
Declaration
public Texture ColorOverLifeTexture
  Field Value
| Type | Description | 
|---|---|
| Texture | 
Description
The particle emitter description.
Declaration
public ParticleEmitterDescription Description
  Field Value
| Type | Description | 
|---|---|
| ParticleEmitterDescription | 
SizeCurveArray
The array with the values of the size over life curve.
Declaration
public float[] SizeCurveArray
  Field Value
| Type | Description | 
|---|---|
| float[] | 
SizeOverLifeTexture
The texture that represents the size over life.
Declaration
public Texture SizeOverLifeTexture
  Field Value
| Type | Description | 
|---|---|
| Texture | 
Properties
ColorAnimated
Gets or sets a value indicating whether the particle color is animated during its lifetime.
Declaration
[RenderProperty(Tag = 7, CustomPropertyName = "Color Animated", Tooltip = "Indicating if a particle color will be changed during its life.")]
public bool ColorAnimated { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
ColorOverLife1
Gets or sets the 1st color of the color over life gradient.
Declaration
[RenderProperty(AttachToTag = 7, AttachToValue = true)]
public Color ColorOverLife1 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Color | 
ColorOverLife2
Gets or sets the 2nd color of the color over life gradient.
Declaration
[RenderProperty(AttachToTag = 7, AttachToValue = true)]
public Color ColorOverLife2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Color | 
ColorOverLife2Position
Gets or sets the relative position on the lifetime of the 2nd step.
Declaration
[RenderPropertyAsFInput(0, 1, AsSlider = true, DesiredChange = 0.05, DesiredLargeChange = 0.2, AttachToValue = true, AttachToTag = 7)]
public float ColorOverLife2Position { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
ColorOverLife3
Gets or sets the 3rd color of the color over life gradient.
Declaration
[RenderProperty(AttachToTag = 7, AttachToValue = true)]
public Color ColorOverLife3 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Color | 
ColorOverLife3Position
Gets or sets the relative position on the lifetime of the 3rd step.
Declaration
[RenderPropertyAsFInput(0, 1, AsSlider = true, DesiredChange = 0.05, DesiredLargeChange = 0.2, AttachToValue = true, AttachToTag = 7)]
public float ColorOverLife3Position { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
ColorOverLife4
Gets or sets the 4th color of the color over life gradient.
Declaration
[RenderProperty(AttachToTag = 7, AttachToValue = true)]
public Color ColorOverLife4 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Color | 
Drag
Gets or sets the drag strength of the particle system.
Declaration
public float Drag { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
ForcesCategory
Gets or sets a value indicating whether the particle forces are enabled for this system.
Declaration
[RenderProperty(AttachToTag = 10, AttachToValue = true)]
public CollisionCategory3D ForcesCategory { get; set; }
  Property Value
| Type | Description | 
|---|---|
| CollisionCategory3D | 
ForcesEnabled
Gets or sets a value indicating whether the particle forces are enabled for this system.
Declaration
[RenderProperty(Tag = 10, CustomPropertyName = "Forces enabled", Tooltip = "Indicating whether a particle will be affected by external forces.")]
public bool ForcesEnabled { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
Gravity
Gets or sets the particle gravity.
Declaration
public float Gravity { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitAngle
Gets or sets the init particle angle.
Declaration
public float InitAngle { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitAngle2
Gets or sets the init particle angle.
Declaration
[RenderProperty(AttachToTag = 3, AttachToValue = ParameterMode.RandomBetweenTwoConstants)]
public float InitAngle2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitAngleMode
Gets or sets the init angle generation mode.
Declaration
[RenderProperty(Tag = 3, CustomPropertyName = "Init Angle mode", Tooltip = "Indicating which strategy will choose to set the initial angle of a particle.")]
public ParameterMode InitAngleMode { get; set; }
  Property Value
| Type | Description | 
|---|---|
| ParameterMode | 
InitAngularSpeed
Gets or sets the particle initial angular velocity.
Declaration
public float InitAngularSpeed { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitAngularSpeed2
Gets or sets the particle initial angular velocity.
Declaration
[RenderProperty(AttachToTag = 4, AttachToValue = ParameterMode.RandomBetweenTwoConstants)]
public float InitAngularSpeed2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitAngularSpeedMode
Gets or sets the init Angular Speed generation mode.
Declaration
[RenderProperty(Tag = 4, CustomPropertyName = "Init Angular Speed mode", Tooltip = "Indicating which strategy will choose to set the initial angular velocity of a particle.")]
public ParameterMode InitAngularSpeedMode { get; set; }
  Property Value
| Type | Description | 
|---|---|
| ParameterMode | 
InitColor
Gets or sets the init particle color.
Declaration
public Color InitColor { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Color | 
InitColor2
Gets or sets the init particle color.
Declaration
[RenderProperty(AttachToTag = 1, AttachToValue = ParameterMode.RandomBetweenTwoConstants)]
public Color InitColor2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Color | 
InitColorLineal
Gets the init color value.
Declaration
public LinearColor InitColorLineal { get; }
  Property Value
| Type | Description | 
|---|---|
| LinearColor | 
InitColorLineal2
Gets the initColor 2 value.
Declaration
public LinearColor InitColorLineal2 { get; }
  Property Value
| Type | Description | 
|---|---|
| LinearColor | 
InitColorMode
Gets or sets the init color generation mode.
Declaration
[RenderProperty(Tag = 1, CustomPropertyName = "Init Color mode", Tooltip = "Indicating which strategy will choose to set the initial color of a particle.")]
public ParameterMode InitColorMode { get; set; }
  Property Value
| Type | Description | 
|---|---|
| ParameterMode | 
InitLife
Gets or sets the particle initial life.
Declaration
public float InitLife { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitLife2
Gets or sets the particle initial life.
Declaration
[RenderProperty(AttachToTag = 5, AttachToValue = ParameterMode.RandomBetweenTwoConstants)]
public float InitLife2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitLifeMode
Gets or sets the init Life generation mode.
Declaration
[RenderProperty(Tag = 5, CustomPropertyName = "Init Life mode", Tooltip = "Indicating which strategy will choose to set the initial life of a particle.")]
public ParameterMode InitLifeMode { get; set; }
  Property Value
| Type | Description | 
|---|---|
| ParameterMode | 
InitSize
Gets or sets the particle initial size.
Declaration
public float InitSize { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitSize2
Gets or sets the particle initial size.
Declaration
[RenderProperty(AttachToTag = 6, AttachToValue = ParameterMode.RandomBetweenTwoConstants)]
public float InitSize2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitSizeMode
Gets or sets the init Size generation mode.
Declaration
[RenderProperty(Tag = 6, CustomPropertyName = "Init Size mode", Tooltip = "Indicating which strategy will choose to set the initial size of a particle.")]
public ParameterMode InitSizeMode { get; set; }
  Property Value
| Type | Description | 
|---|---|
| ParameterMode | 
InitSpeed
Gets or sets the init particle velocity.
Declaration
public float InitSpeed { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitSpeed2
Gets or sets the init particle velocity.
Declaration
[RenderProperty(AttachToTag = 2, AttachToValue = ParameterMode.RandomBetweenTwoConstants)]
public float InitSpeed2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
InitSpeedMode
Gets or sets the init velocity generation mode.
Declaration
[RenderProperty(Tag = 2, CustomPropertyName = "Init Speed mode", Tooltip = "Indicating which strategy will choose to set the initial velocify of a particle.")]
public ParameterMode InitSpeedMode { get; set; }
  Property Value
| Type | Description | 
|---|---|
| ParameterMode | 
InvNoiseSize
Gets the inverse of the noise size.
Declaration
public float InvNoiseSize { get; }
  Property Value
| Type | Description | 
|---|---|
| float | 
MaxParticles
Gets or sets the max amount of particles of the system.
Declaration
public uint MaxParticles { get; set; }
  Property Value
| Type | Description | 
|---|---|
| uint | 
NoiseEnabled
Gets or sets a value indicating whether the particle noise field is enabled for this system.
Declaration
[RenderProperty(Tag = 9, CustomPropertyName = "Noise enabled")]
public bool NoiseEnabled { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
NoiseFrequency
Gets or sets the noise frequency.
Declaration
[RenderProperty(AttachToTag = 9, AttachToValue = true)]
public float NoiseFrequency { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
NoiseSize
Gets or sets the noise size.
Declaration
[RenderProperty(AttachToTag = 9, AttachToValue = true)]
public float NoiseSize { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
NoiseStrength
Gets or sets the noise strength.
Declaration
[RenderProperty(AttachToTag = 9, AttachToValue = true)]
public float NoiseStrength { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
NoiseVelocity
Gets or sets the noise velocity.
Declaration
[RenderProperty(AttachToTag = 9, AttachToValue = true)]
public Vector3 NoiseVelocity { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Vector3 | 
PreserveHighlights
Gets or sets a value indicating whether the tint color doesn't affect the highlights.
Declaration
public bool PreserveHighlights { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
RandomPrecission
Gets or sets the random precission level of the particl system.
Declaration
public RandomPrecissionEnum RandomPrecission { get; set; }
  Property Value
| Type | Description | 
|---|---|
| RandomPrecissionEnum | 
RenderLayer
Gets or sets the particle emitter render layer.
Declaration
public RenderLayerDescription RenderLayer { get; set; }
  Property Value
| Type | Description | 
|---|---|
| RenderLayerDescription | 
SamplerState
Gets or sets the particle emitter sampler state.
Declaration
public SamplerState SamplerState { get; set; }
  Property Value
| Type | Description | 
|---|---|
| SamplerState | 
ShapeEmitter
Gets or sets the spawn instance.
Declaration
public BaseShapeEmitter ShapeEmitter { get; set; }
  Property Value
| Type | Description | 
|---|---|
| BaseShapeEmitter | 
SimulationSpace
Gets or sets the simulation space of the particle system.
Declaration
public SimulationSpaceMode SimulationSpace { get; set; }
  Property Value
| Type | Description | 
|---|---|
| SimulationSpaceMode | 
SizeAnimated
Gets or sets a value indicating whether the particle size is animated during its lifetime.
Declaration
[RenderProperty(Tag = 8, CustomPropertyName = "Size Animated", Tooltip = "Indicating if a particle size will be changed during its life.")]
public bool SizeAnimated { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
SizeOverLife1
Gets or sets the 1st size of the size over life curve.
Declaration
[RenderProperty(AttachToTag = 8, AttachToValue = true)]
public float SizeOverLife1 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
SizeOverLife2
Gets or sets the 2nd size of the size over life curve.
Declaration
[RenderProperty(AttachToTag = 8, AttachToValue = true)]
public float SizeOverLife2 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
SizeOverLife2Position
Gets or sets the relative position on the lifetime of the 2nd step.
Declaration
[RenderPropertyAsFInput(0, 1, AsSlider = true, DesiredChange = 0.05, DesiredLargeChange = 0.2, AttachToValue = true, AttachToTag = 8)]
public float SizeOverLife2Position { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
SizeOverLife3
Gets or sets the 3rd size of the size over life curve.
Declaration
[RenderProperty(AttachToTag = 8, AttachToValue = true)]
public float SizeOverLife3 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
SizeOverLife3Position
Gets or sets the relative position on the lifetime of the 3rd step.
Declaration
[RenderPropertyAsFInput(0, 1, AsSlider = true, DesiredChange = 0.05, DesiredLargeChange = 0.2, AttachToValue = true, AttachToTag = 8)]
public float SizeOverLife3Position { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
SizeOverLife4
Gets or sets the 4th size of the size over life curve.
Declaration
[RenderProperty(AttachToTag = 8, AttachToValue = true)]
public float SizeOverLife4 { get; set; }
  Property Value
| Type | Description | 
|---|---|
| float | 
Spawn
Gets or sets the spawn instance.
Declaration
public BaseSpawn Spawn { get; set; }
  Property Value
| Type | Description | 
|---|---|
| BaseSpawn | 
Texture
Gets or sets the particle emitter texture.
Declaration
public Texture Texture { get; set; }
  Property Value
| Type | Description | 
|---|---|
| Texture | 
Methods
RaisePropertyChanged(string)
Raise the PropertyChanged event of the given property.
Declaration
protected virtual void RaisePropertyChanged(string propertyName = "")
  Parameters
| Type | Name | Description | 
|---|---|---|
| string | propertyName | The porperty name.  | 
      
RaiseSizeChanged(string)
Raise the SizeChanged event of the given property.
Declaration
protected virtual void RaiseSizeChanged(string propertyName = "")
  Parameters
| Type | Name | Description | 
|---|---|---|
| string | propertyName | The porperty name.  | 
      
Events
PropertyChanged
Event launched when the property has been changed.
Declaration
public event EventHandler<string> PropertyChanged
  Event Type
| Type | Description | 
|---|---|
| EventHandler<string> | 
ShapeChanged
Event launched when the shape has been changed.
Declaration
public event EventHandler<EmitterShapes> ShapeChanged
  Event Type
| Type | Description | 
|---|---|
| EventHandler<EmitterShapes> | 
SizeChanged
Event launched when the size has been changed.
Declaration
public event EventHandler<string> SizeChanged
  Event Type
| Type | Description | 
|---|---|
| EventHandler<string> |