ParticleSystemSolver3.h
Go to the documentation of this file.
140 void ResolveCollision(ArrayAccessor1<Vector3D> newPositions, ArrayAccessor1<Vector3D> newVelocities);
ParticleSystemSolver3Ptr MakeShared() const
Builds shared pointer of ParticleSystemSolver3 instance.
Front-end to create ParticleSystemSolver3 objects step by step.
Definition: ParticleSystemSolver3.h:208
std::shared_ptr< Collider3 > Collider3Ptr
Shared pointer type for the Collider3.
Definition: Collider3.h:112
void OnInitialize() override
Initializes the simulator.
std::shared_ptr< ParticleEmitter3 > ParticleEmitter3Ptr
Shared pointer for the ParticleEmitter3 type.
Definition: ParticleEmitter3.h:71
ParticleSystemSolver3 Build() const
Builds ParticleSystemSolver3.
void ResolveCollision()
Resolves any collisions occurred by the particles.
const Collider3Ptr & GetCollider() const
Returns the collider.
const ParticleEmitter3Ptr & GetEmitter() const
Returns the emitter.
Basic 3-D particle system solver.
Definition: ParticleSystemSolver3.h:34
std::shared_ptr< ParticleSystemData3 > ParticleSystemData3Ptr
Shared pointer type of ParticleSystemData3.
Definition: ParticleSystemData3.h:250
std::shared_ptr< VectorField3 > VectorField3Ptr
Shared pointer for the VectorField3 type.
Definition: VectorField3.h:44
virtual void AccumulateForces(double timeStepInSeconds)
Accumulates forces applied to the particles.
ParticleSystemSolver3()
Constructs an empty solver.
const VectorField3Ptr & GetWind() const
Returns the wind field.
const ParticleSystemData3Ptr & GetParticleSystemData() const
Returns the particle system data.
void SetParticleSystemData(const ParticleSystemData3Ptr &newParticles)
Assign a new particle system data.
void SetCollider(const Collider3Ptr &newCollider)
Sets the collider.
void SetEmitter(const ParticleEmitter3Ptr &newEmitter)
Sets the emitter.
Base class for particle-based solver builder.
Definition: ParticleSystemSolver3.h:177
Abstract base class for physics-based animation.
Definition: PhysicsAnimation.h:22
void SetRestitutionCoefficient(double newRestitutionCoefficient)
Sets the restitution coefficient.
DerivedBuilder & WithRadius(double radius)
Returns builder with particle radius.
Definition: ParticleSystemSolver3.h:192
Definition: pybind11Utils.h:24
double m_radius
Definition: ParticleSystemSolver3.h:187
virtual void OnBeginAdvanceTimeStep(double timeStepInSeconds)
Called when a time-step is about to begin.
static Builder GetBuilder()
Returns builder fox ParticleSystemSolver3.
double GetRestitutionCoefficient() const
Gets the restitution coefficient.
double m_mass
Definition: ParticleSystemSolver3.h:188
double GetDragCoefficient() const
Returns the drag coefficient.
void SetGravity(const Vector3D &newGravity)
Sets the gravity.
virtual void OnEndAdvanceTimeStep(double timeStepInSeconds)
Called after a time-step is completed.
void OnAdvanceTimeStep(double timeStepInSeconds) override
Called to advance a single time-step.
DerivedBuilder & WithMass(double mass)
Returns builder with mass per particle.
Definition: ParticleSystemSolver3.h:199
void SetDragCoefficient(double newDragCoefficient)
Sets the drag coefficient.
std::shared_ptr< ParticleSystemSolver3 > ParticleSystemSolver3Ptr
Shared pointer type for the ParticleSystemSolver3.
Definition: ParticleSystemSolver3.h:171