openscenegraph
Public Types | Public Member Functions | Protected Attributes | List of all members
osgAnimation::Motion Class Referenceabstract

#include <EaseMotion>

Inheritance diagram for osgAnimation::Motion:
osg::Referenced osgAnimation::CompositeMotion osgAnimation::MathMotionTemplate< T > osgAnimation::SamplerMotionTemplate< T >

Public Types

enum  TimeBehaviour { CLAMP , LOOP }
 
typedef float value_type
 

Public Member Functions

 Motion (float startValue=0, float duration=1, float changeValue=1, TimeBehaviour tb=CLAMP)
 
virtual ~Motion ()
 
void reset ()
 
float getTime () const
 
float evaluateTime (float time) const
 
void update (float dt)
 
void setTime (float time)
 
void getValue (value_type &result) const
 
value_type getValue () const
 
void getValueAt (float time, value_type &result) const
 
value_type getValueAt (float time) const
 
virtual void getValueInNormalizedRange (float t, value_type &result) const =0
 
float getDuration () const
 
- Public Member Functions inherited from osg::Referenced
 Referenced ()
 
 Referenced (bool threadSafeRefUnref)
 
 Referenced (const Referenced &)
 
Referencedoperator= (const Referenced &)
 
virtual void setThreadSafeRefUnref (bool)
 
bool getThreadSafeRefUnref () const
 
OpenThreads::MutexgetRefMutex () const
 
int ref () const
 
int unref () const
 
int unref_nodelete () const
 
int referenceCount () const
 
ObserverSetgetObserverSet () const
 
ObserverSetgetOrCreateObserverSet () const
 
void addObserver (Observer *observer) const
 
void removeObserver (Observer *observer) const
 

Protected Attributes

float _time
 
float _startValue
 
float _changeValue
 
float _duration
 
TimeBehaviour _behaviour
 
- Protected Attributes inherited from osg::Referenced
OpenThreads::AtomicPtr _observerSet
 
OpenThreads::Atomic _refCount
 

Additional Inherited Members

- Static Public Member Functions inherited from osg::Referenced
static OpenThreads::MutexgetGlobalReferencedMutex ()
 
static void setDeleteHandler (DeleteHandler *handler)
 
static DeleteHandlergetDeleteHandler ()
 
- Protected Member Functions inherited from osg::Referenced
virtual ~Referenced ()
 
void signalObserversAndDelete (bool signalDelete, bool doDelete) const
 
void deleteUsingDeleteHandler () const
 

Member Typedef Documentation

◆ value_type

Member Enumeration Documentation

◆ TimeBehaviour

Enumerator
CLAMP 
LOOP 

Constructor & Destructor Documentation

◆ Motion()

osgAnimation::Motion::Motion ( float  startValue = 0,
float  duration = 1,
float  changeValue = 1,
TimeBehaviour  tb = CLAMP 
)
inline

◆ ~Motion()

virtual osgAnimation::Motion::~Motion ( )
inlinevirtual

Member Function Documentation

◆ evaluateTime()

float osgAnimation::Motion::evaluateTime ( float  time) const
inline

◆ getDuration()

float osgAnimation::Motion::getDuration ( ) const
inline

◆ getTime()

float osgAnimation::Motion::getTime ( ) const
inline

◆ getValue() [1/2]

value_type osgAnimation::Motion::getValue ( ) const
inline

◆ getValue() [2/2]

void osgAnimation::Motion::getValue ( value_type result) const
inline

◆ getValueAt() [1/2]

value_type osgAnimation::Motion::getValueAt ( float  time) const
inline

◆ getValueAt() [2/2]

void osgAnimation::Motion::getValueAt ( float  time,
value_type result 
) const
inline

◆ getValueInNormalizedRange()

virtual void osgAnimation::Motion::getValueInNormalizedRange ( float  t,
value_type result 
) const
pure virtual

◆ reset()

void osgAnimation::Motion::reset ( )
inline

◆ setTime()

void osgAnimation::Motion::setTime ( float  time)
inline

◆ update()

void osgAnimation::Motion::update ( float  dt)
inline

Member Data Documentation

◆ _behaviour

TimeBehaviour osgAnimation::Motion::_behaviour
protected

◆ _changeValue

float osgAnimation::Motion::_changeValue
protected

◆ _duration

float osgAnimation::Motion::_duration
protected

◆ _startValue

float osgAnimation::Motion::_startValue
protected

◆ _time

float osgAnimation::Motion::_time
protected

The documentation for this class was generated from the following file: