5#ifndef JPP_I_SCENE_NODE_ANIMATOR_HPP_INCLUDED
6#define JPP_I_SCENE_NODE_ANIMATOR_HPP_INCLUDED
8#include <jimcpp/core/engine/IReferenceCounted.hpp>
9#include <jimcpp/core/engine/vector3d.hpp>
10#include <jimcpp/core/engine/ESceneNodeAnimatorTypes.hpp>
11#include <jimcpp/core/engine/IAttributeExchangingObject.hpp>
12#include <jimcpp/core/engine/IAttributes.hpp>
13#include <jimcpp/core/engine/IEventReceiver.hpp>
112 if ( enabled == IsEnabled )
126 virtual bool isEnabled()
const
134 out->
addBool(
"IsEnabled", IsEnabled);
153 IsEnabled = toCopyFrom->IsEnabled;
Interface of an object which can receive events.
Definition IEventReceiver.hpp:484
SEvents hold information about an event. See jpp::IEventReceiver for details on event handling.
Definition IEventReceiver.hpp:282
An object which is able to serialize and deserialize its attributes into an attributes object.
Definition IAttributeExchangingObject.hpp:54
Provides a generic interface for attributes and their values and the possibility to serialize them.
Definition IAttributes.hpp:42
virtual bool getAttributeAsBool(const c8 *attributeName, bool defaultNotFound=false) const =0
virtual void addBool(const c8 *attributeName, bool value)=0
Adds an attribute as bool.
class holding data describing options
Definition IAttributeExchangingObject.hpp:35
The Scene Manager manages scene nodes, mesh resources, cameras and all the other stuff.
Definition ISceneManager.hpp:160
Animates a scene node. Can animate position, rotation, material, and so on.
Definition ISceneNodeAnimator.hpp:32
virtual jpp::u32 getStartTime() const
Get the starttime.
Definition ISceneNodeAnimator.hpp:96
void cloneMembers(const ISceneNodeAnimator *toCopyFrom)
Definition ISceneNodeAnimator.hpp:151
virtual bool hasFinished(void) const
Returns if the animator has finished.
Definition ISceneNodeAnimator.hpp:72
virtual void setStartTime(u32 time, bool resetPauseTime=true)
Reset a time-based movement by changing the starttime.
Definition ISceneNodeAnimator.hpp:84
virtual void setEnabled(bool enabled, u32 timeNow=0)
Sets the enabled state of this element.
Definition ISceneNodeAnimator.hpp:110
virtual bool OnEvent(const SEvent &event) override
Event receiver, override this function for camera controlling animators.
Definition ISceneNodeAnimator.hpp:58
virtual void animateNode(ISceneNode *node, u32 timeMs)=0
Animates a scene node.
u32 PauseTimeStart
Sum up time which the animator was disabled.
Definition ISceneNodeAnimator.hpp:161
virtual bool isEventReceiverEnabled() const
Returns true if this animator receives events.
Definition ISceneNodeAnimator.hpp:52
u32 StartTime
Last time setEnabled(false) was called with a timer > 0.
Definition ISceneNodeAnimator.hpp:162
virtual void deserializeAttributes(io::IAttributes *in, io::SAttributeReadWriteOptions *options=0) override
Reads attributes of the scene node animator.
Definition ISceneNodeAnimator.hpp:139
virtual void serializeAttributes(io::IAttributes *out, io::SAttributeReadWriteOptions *options=0) const override
Writes attributes of the scene node animator.
Definition ISceneNodeAnimator.hpp:132
u32 PauseTimeSum
Only enabled animators are updated.
Definition ISceneNodeAnimator.hpp:160
virtual ISceneNodeAnimator * createClone(ISceneNode *node, ISceneManager *newManager=0)=0
Creates a clone of this animator.
virtual ESCENE_NODE_ANIMATOR_TYPE getType() const
Returns type of the scene node animator.
Definition ISceneNodeAnimator.hpp:64
Scene node interface.
Definition ISceneNode.hpp:43
ESCENE_NODE_ANIMATOR_TYPE
An enumeration for all types of built-in scene node animators.
Definition ESceneNodeAnimatorTypes.hpp:15
@ ESNAT_UNKNOWN
Unknown scene node animator.
Definition ESceneNodeAnimatorTypes.hpp:47
As of Jimcpp 1.6, position2d is a synonym for vector2d.
Definition vector3d.hpp:11
unsigned int u32
32 bit unsigned variable.
Definition irrTypes.hpp:64