26 using std::unique_ptr;
88 object->setScale(
scale);
122 const string&
getId()
override;
213 this->localTransform = transform;
Color 4 definition class.
Object to be used with engine class.
Representation of a 3D model.
Axis aligned bounding box used for frustum, this is not directly connectable with physics engine.
Particle system which displays objects as particles.
void updateParticles() override
Updates the particle entity.
void setContributesShadows(bool contributesShadows)
Enable/disable contributes shadows.
void setLocalTransform(const Transform &transform) override
Set local transform.
void setEngine(Engine *engine)
Transform parentTransform
unique_ptr< ParticleEmitter > emitter
vector< Object * > objects
BoundingBox worldBoundingBox
virtual ~ObjectParticleSystemInternal()
Destructor.
void setParentTransform(const Transform &transform)
const Transform & getParentTransform()
void update() override
Update transform.
vector< Particle > particles
const string & getId() override
void setPickable(bool pickable) override
Set this object pickable.
void setEffectColorMul(const Color4 &effectColorMul) override
Set the effect color that will be multiplied with fragment color.
bool isContributesShadows()
Matrix4x4 inverseTransformMatrix
bool isPickable() override
ParticleEmitter * getEmitter() override
Matrix4x4 entityTransformMatrix
void setTransform(const Transform &transform) override
Set transform.
vector< Object * > enabledObjects
bool isAutoEmit() override
ObjectParticleSystemInternal(const string &id, Model *model, const Vector3 &scale, bool autoEmit, bool contributesShadows, bool receivesShadows, int32_t maxCount, ParticleEmitter *emitter)
Public constructor.
const Color4 & getEffectColorMul() const override
The effect color will be multiplied with fragment color.
void setAutoEmit(bool autoEmit) override
Set auto emit.
void setRenderer(Renderer *renderer)
void setEnabled(bool enabled) override
Enable/disable rendering.
float particlesToSpawnRemainder
void updateInternal()
Update internal.
bool isEnabled() override
int emitParticles() override
Adds particles to this particle entity at given position.
void setReceivesShadows(bool receivesShadows)
Enable/disable receives shadows.
void setEffectColorAdd(const Color4 &effectColorAdd) override
Set the effect color that will be added to fragment color.
const Color4 & getEffectColorAdd() const override
The effect color will be added to fragment color.
const Transform & getLocalTransform() override
Matrix4x4 class representing matrix4x4 mathematical structure and operations for 3d space.
Matrix4x4 & invert()
Inverts this matrix.
void getScale(Vector3 &scale) const
Get scale.
Vector3 class representing vector3 mathematical structure and operations with x, y,...
Vector3 & scale(float scalar)
Scales by scalar.
Particle emitter interface.
Particle system entity internal interface.
#define FORBID_CLASS_COPY(CLASS)