class EE::Scene::Actions::Tint¶
Overview¶
#include <tint.hpp> class Tint: public EE::Scene::Action { public: // enums enum TintType; // methods static Tint* New( const Color& start, const Color& end, const bool& interpolateAlpha, const Time& duration, const Ease::Interpolation& type = Ease::Linear, const TintType& colorInterpolationType = Background, const Uint32& elemIndex = 0 ); virtual void start(); virtual void stop(); virtual void update(const Time& time); virtual bool isDone(); virtual Action* clone() const; virtual Action* reverse() const; virtual Float getCurrentProgress(); virtual Time getTotalTime(); Interpolation1d getInterpolationR() const; void setInterpolationR(const Interpolation1d& interpolationR); Interpolation1d getInterpolationG() const; void setInterpolationG(const Interpolation1d& interpolationG); Interpolation1d getInterpolationB() const; void setInterpolationB(const Interpolation1d& interpolationB); Interpolation1d getInterpolationA() const; void setInterpolationA(const Interpolation1d& interpolationA); };
Inherited Members¶
public: // typedefs typedef std::function<void(Action*, const ActionType&)> ActionCallback; typedef Uint64 UniqueID; // enums enum ActionType; // methods virtual void start() = 0; virtual void stop() = 0; virtual void update(const Time& time) = 0; virtual bool isDone() = 0; virtual Float getCurrentProgress() = 0; virtual Time getTotalTime() = 0; virtual Action* clone() const; virtual Action* reverse() const; Uint32 getFlags() const; void setFlags(const Uint32& flags); UniqueID getTag() const; void setTag(const UniqueID& tag); Node* getTarget() const; Uint32 addEventListener(const ActionType& actionType, const ActionCallback& callback); Action* on(const ActionType& actionType, const ActionCallback& callback); void removeEventListener(const Uint32& callbackId); void sendEvent(const ActionType& actionType); void setTarget(Node* target); void setId(const Action::UniqueID& id); const Action::UniqueID& getId();
Detailed Documentation¶
Methods¶
virtual void start()
Starts the action.
virtual void stop()
Stops the actions (pause it, it will not reset the animation state).
virtual void update(const Time& time)
Update the action state (shouldn’t be called manually unless you actually now what you are doing)
virtual bool isDone()
Returns:
If the action is completed.
virtual Action* clone() const
Clones the action.
virtual Action* reverse() const
Clones and reverse the action sequence. Note: not all actions can be reversed.
virtual Float getCurrentProgress()
Returns:
The current progress percentage. Normalized between 0 and 1.
virtual Time getTotalTime()
The total action time.