using System;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
namespace BansheeEngine
{
/** @addtogroup Particles
* @{
*/
/// Handles spawning of new particles using the specified parameters and shape.
public partial class ParticleEmitter : ScriptObject
{
private ParticleEmitter(bool __dummy0) { }
/// Creates a new emitter.
public ParticleEmitter()
{
Internal_create(this);
}
/// Shape over which to emit the particles.
public ParticleEmitterShape Shape
{
get { return Internal_getShape(mCachedPtr); }
set { Internal_setShape(mCachedPtr, value); }
}
/// Determines the number of particles that are emitted every second.
public FloatDistribution EmissionRate
{
get { return Internal_getEmissionRate(mCachedPtr); }
set { Internal_setEmissionRate(mCachedPtr, value); }
}
/// Determines discrete intervals to emit particles.
public ParticleBurst[] EmissionBursts
{
get { return Internal_getEmissionBursts(mCachedPtr); }
set { Internal_setEmissionBursts(mCachedPtr, value); }
}
/// Determines the lifetime of particles when they are initially spawned, in seconds.
public FloatDistribution InitialLifetime
{
get { return Internal_getInitialLifetime(mCachedPtr); }
set { Internal_setInitialLifetime(mCachedPtr, value); }
}
///
/// Sets the initial speed of the particles, in meters/second. The speed is applied along the particle's velocity
/// direction, which is determined by the emission shape and potentially other properties.
///
public FloatDistribution InitialSpeed
{
get { return Internal_getInitialSpeed(mCachedPtr); }
set { Internal_setInitialSpeed(mCachedPtr, value); }
}
///
/// Determines the size of the particles when initially spawned. The size is applied uniformly in all dimensions. Only
/// used if 3D size is disabled.
///
public FloatDistribution InitialSize
{
get { return Internal_getInitialSize(mCachedPtr); }
set { Internal_setInitialSize(mCachedPtr, value); }
}
///
/// Determines the size of the particles when initially spawned. Size can be specified for each dimension separately.
/// Only used if 3D size is enabled.
///
public Vector3Distribution InitialSize3D
{
get { return Internal_getInitialSize3D(mCachedPtr); }
set { Internal_setInitialSize3D(mCachedPtr, value); }
}
///
/// Determines should the initial particle size be applied uniformly (if disabled), or evaluated separately for each
/// dimension (if enabled).
///
public bool Use3DSize
{
get { return Internal_getUse3DSize(mCachedPtr); }
set { Internal_setUse3DSize(mCachedPtr, value); }
}
///
/// Determines the rotation of the particles when initially spawned, in degrees. The rotation is applied around the
/// particle's local Z axis. Only used if 3D rotation is disabled.
///
public FloatDistribution InitialRotation
{
get { return Internal_getInitialRotation(mCachedPtr); }
set { Internal_setInitialRotation(mCachedPtr, value); }
}
///
/// Determines the rotation of the particles when initially spawned, in Euler angles. Only used if 3D rotation is enabled.
///
public Vector3Distribution InitialRotation3D
{
get { return Internal_getInitialRotation3D(mCachedPtr); }
set { Internal_setInitialRotation3D(mCachedPtr, value); }
}
///
/// Determines should the initial particle rotation be a single angle applied around a Z axis (if disabled), or a set of
/// Euler angles that allow you to rotate around every axis (if enabled).
///
public bool Use3DRotation
{
get { return Internal_getUse3DRotation(mCachedPtr); }
set { Internal_setUse3DRotation(mCachedPtr, value); }
}
/// Determines the initial color (in RGB channels) and transparency (in A channel) of particles.
public ColorDistribution InitialColor
{
get { return Internal_getInitialColor(mCachedPtr); }
set { Internal_setInitialColor(mCachedPtr, value); }
}
///
/// Determines a range of values determining a random offset to apply to particle position after it has been emitted.
/// Offset will be randomly selected in all three axes in range [-value, value].
///
public float RandomOffset
{
get { return Internal_getRandomOffset(mCachedPtr); }
set { Internal_setRandomOffset(mCachedPtr, value); }
}
///
/// Determines should particle U texture coordinate be randomly flipped, mirroring the image. The value represents a
/// percent of particles that should be flipped, in range [0, 1].
///
public float FlipU
{
get { return Internal_getFlipU(mCachedPtr); }
set { Internal_setFlipU(mCachedPtr, value); }
}
///
/// Determines should particle V texture coordinate be randomly flipped, mirroring the image. The value represents a
/// percent of particles that should be flipped, in range [0, 1].
///
public float FlipV
{
get { return Internal_getFlipV(mCachedPtr); }
set { Internal_setFlipV(mCachedPtr, value); }
}
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setShape(IntPtr thisPtr, ParticleEmitterShape shape);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern ParticleEmitterShape Internal_getShape(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setEmissionRate(IntPtr thisPtr, FloatDistribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern FloatDistribution Internal_getEmissionRate(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setEmissionBursts(IntPtr thisPtr, ParticleBurst[] bursts);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern ParticleBurst[] Internal_getEmissionBursts(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setInitialLifetime(IntPtr thisPtr, FloatDistribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern FloatDistribution Internal_getInitialLifetime(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setInitialSpeed(IntPtr thisPtr, FloatDistribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern FloatDistribution Internal_getInitialSpeed(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setInitialSize(IntPtr thisPtr, FloatDistribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern FloatDistribution Internal_getInitialSize(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setInitialSize3D(IntPtr thisPtr, Vector3Distribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern Vector3Distribution Internal_getInitialSize3D(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setUse3DSize(IntPtr thisPtr, bool value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern bool Internal_getUse3DSize(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setInitialRotation(IntPtr thisPtr, FloatDistribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern FloatDistribution Internal_getInitialRotation(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setInitialRotation3D(IntPtr thisPtr, Vector3Distribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern Vector3Distribution Internal_getInitialRotation3D(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setUse3DRotation(IntPtr thisPtr, bool value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern bool Internal_getUse3DRotation(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setInitialColor(IntPtr thisPtr, ColorDistribution value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern ColorDistribution Internal_getInitialColor(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setRandomOffset(IntPtr thisPtr, float value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern float Internal_getRandomOffset(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setFlipU(IntPtr thisPtr, float value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern float Internal_getFlipU(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_setFlipV(IntPtr thisPtr, float value);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern float Internal_getFlipV(IntPtr thisPtr);
[MethodImpl(MethodImplOptions.InternalCall)]
private static extern void Internal_create(ParticleEmitter managedInstance);
}
/** @} */
}