Abstract base class for 2-D particle emitter. More...
#include <Core/Emitter/ParticleEmitter2.hpp>
 
  
 | Public Types | |
| using | OnBeginUpdateCallback = std::function< void(ParticleEmitter2 *, double, double)> | 
| Callback function type for update calls.  More... | |
| Public Member Functions | |
| ParticleEmitter2 ()=default | |
| Default constructor.  More... | |
| ParticleEmitter2 (const ParticleEmitter2 &)=default | |
| Default copy constructor.  More... | |
| ParticleEmitter2 (ParticleEmitter2 &&) noexcept=default | |
| Default move constructor.  More... | |
| virtual | ~ParticleEmitter2 ()=default | 
| Default virtual destructor.  More... | |
| ParticleEmitter2 & | operator= (const ParticleEmitter2 &)=default | 
| Default copy assignment operator.  More... | |
| ParticleEmitter2 & | operator= (ParticleEmitter2 &&) noexcept=default | 
| Default move assignment operator.  More... | |
| void | Update (double currentTimeInSeconds, double timeIntervalInSeconds) | 
| const ParticleSystemData2Ptr & | GetTarget () const | 
| Returns the target particle system to emit.  More... | |
| void | SetTarget (const ParticleSystemData2Ptr &particles) | 
| Sets the target particle system to emit.  More... | |
| bool | GetIsEnabled () const | 
| Returns true if the emitter is enabled.  More... | |
| void | SetIsEnabled (bool enabled) | 
| Sets true/false to enable/disable the emitter.  More... | |
| void | SetOnBeginUpdateCallback (const OnBeginUpdateCallback &callback) | 
| Sets the callback function to be called when ParticleEmitter2::Update function is invoked.  More... | |
| Protected Member Functions | |
| virtual void | OnSetTarget (const ParticleSystemData2Ptr &particles) | 
| Called when ParticleEmitter2::SetTarget is executed.  More... | |
| virtual void | OnUpdate (double currentTimeInSeconds, double timeIntervalInSeconds)=0 | 
| Called when ParticleEmitter2::Update is executed.  More... | |
Detailed Description
Abstract base class for 2-D particle emitter.
Member Typedef Documentation
◆ OnBeginUpdateCallback
| using CubbyFlow::ParticleEmitter2::OnBeginUpdateCallback = std::function<void(ParticleEmitter2*, double, double)> | 
Callback function type for update calls.
This type of callback function will take the emitter pointer, current time, and time interval in seconds.
Constructor & Destructor Documentation
◆ ParticleEmitter2() [1/3]
| 
 | default | 
Default constructor.
◆ ParticleEmitter2() [2/3]
| 
 | default | 
Default copy constructor.
◆ ParticleEmitter2() [3/3]
| 
 | defaultnoexcept | 
Default move constructor.
◆ ~ParticleEmitter2()
| 
 | virtualdefault | 
Default virtual destructor.
Member Function Documentation
◆ GetIsEnabled()
| bool CubbyFlow::ParticleEmitter2::GetIsEnabled | ( | ) | const | 
Returns true if the emitter is enabled.
◆ GetTarget()
| const ParticleSystemData2Ptr& CubbyFlow::ParticleEmitter2::GetTarget | ( | ) | const | 
Returns the target particle system to emit.
◆ OnSetTarget()
| 
 | protectedvirtual | 
Called when ParticleEmitter2::SetTarget is executed.
◆ OnUpdate()
| 
 | protectedpure virtual | 
Called when ParticleEmitter2::Update is executed.
◆ operator=() [1/2]
| 
 | default | 
Default copy assignment operator.
◆ operator=() [2/2]
| 
 | defaultnoexcept | 
Default move assignment operator.
◆ SetIsEnabled()
| void CubbyFlow::ParticleEmitter2::SetIsEnabled | ( | bool | enabled | ) | 
Sets true/false to enable/disable the emitter.
◆ SetOnBeginUpdateCallback()
| void CubbyFlow::ParticleEmitter2::SetOnBeginUpdateCallback | ( | const OnBeginUpdateCallback & | callback | ) | 
Sets the callback function to be called when ParticleEmitter2::Update function is invoked.
The callback function takes current simulation time in seconds unit. Use this callback to track any motion or state changes related to this emitter.
- Parameters
- 
  [in] callback The callback function. 
◆ SetTarget()
| void CubbyFlow::ParticleEmitter2::SetTarget | ( | const ParticleSystemData2Ptr & | particles | ) | 
Sets the target particle system to emit.
◆ Update()
| void CubbyFlow::ParticleEmitter2::Update | ( | double | currentTimeInSeconds, | 
| double | timeIntervalInSeconds | ||
| ) | 
Updates the emitter state from currentTimeInSeconds to the following time-step. 
The documentation for this class was generated from the following file:
- Core/Emitter/ParticleEmitter2.hpp
 1.8.13
 1.8.13