Gravity Engine 2 3.0
Loading...
Searching...
No Matches
GravityEngine2.IGSParticlesInit Interface Reference

Interface defining methods to be implemented to define particle positions and velocities for GravityParticles. More...

Inheritance diagram for GravityEngine2.IGSParticlesInit:
GravityEngine2.DustBall GravityEngine2.DustRing

Public Member Functions

void InitNewParticles (int fromParticle, int toParticle, GBUnits.GEScaler geScaler, ref NativeArray< double3 > r, ref NativeArray< double3 > v)
 Provide the initial positions and velocity for a range of particles. This method will be called as particles are created by the particle system. The implementing class must fill in the r[] and v[] arrays for the range specified. These arrays are indexed by [particle_num, dimension] where dimension 0,1,2 correspond to x,y,z.
 

Detailed Description

Interface defining methods to be implemented to define particle positions and velocities for GravityParticles.

Member Function Documentation

◆ InitNewParticles()

void GravityEngine2.IGSParticlesInit.InitNewParticles ( int fromParticle,
int toParticle,
GBUnits.GEScaler geScaler,
ref NativeArray< double3 > r,
ref NativeArray< double3 > v )

Provide the initial positions and velocity for a range of particles. This method will be called as particles are created by the particle system. The implementing class must fill in the r[] and v[] arrays for the range specified. These arrays are indexed by [particle_num, dimension] where dimension 0,1,2 correspond to x,y,z.

See the DustBox script for a sample usage of this interface.

Parameters
fromParticle
toParticle
scaleWorldToGE
r
v

Implemented in GravityEngine2.DustBall, and GravityEngine2.DustRing.


The documentation for this interface was generated from the following file: