# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

NL3D::ITrack Class Reference

The track store an animation of an animated value. More...

#include <track.h>

Inheritance diagram for NL3D::ITrack:

NLMISC::IStreamable NL3D::UTrack NLMISC::IClassable NL3D::CTrackSampledCommon NL3D::ITrackDefault NL3D::ITrackKeyFramer NL3D::ITrackKeyFramer< CKeyBezierFloat > NL3D::ITrackKeyFramer< CKeyBezierQuat > NL3D::ITrackKeyFramer< CKeyBezierVector > NL3D::ITrackKeyFramer< CKeyBool > NL3D::ITrackKeyFramer< CKeyFloat > NL3D::ITrackKeyFramer< CKeyInt > NL3D::ITrackKeyFramer< CKeyQuat > NL3D::ITrackKeyFramer< CKeyRGBA > NL3D::ITrackKeyFramer< CKeyString > NL3D::ITrackKeyFramer< CKeyTCBFloat > NL3D::ITrackKeyFramer< CKeyTCBQuat > NL3D::ITrackKeyFramer< CKeyTCBVector > NL3D::ITrackKeyFramer< CKeyVector > List of all members.

Public Methods

virtual ~ITrack ()
 Virtual destructor. More...

virtual void eval (const TAnimationTime &date)=0
 Evaluation of the value of the track for this time. More...

virtual const IAnimatedValuegetValue () const=0
 Get the track current value. More...

virtual bool getLoopMode () const=0
 get LoopMode. More...

From UTrack
virtual bool interpolate (TAnimationTime time, float &res)
 Interplation a float value. More...

virtual bool interpolate (TAnimationTime time, sint32 &res)
 Interplation an integer value. More...

virtual bool interpolate (TAnimationTime time, NLMISC::CRGBA &res)
 Interplation a CRGBA value. More...

virtual bool interpolate (TAnimationTime time, NLMISC::CVector &res)
 Interplation a CVector value. More...

virtual bool interpolate (TAnimationTime time, NLMISC::CQuat &res)
 Interplation a CQuat value. More...

virtual bool interpolate (TAnimationTime time, std::string &res)
 Interplation a string value. More...

virtual bool interpolate (TAnimationTime time, bool &res)
 Interplation a bool value. More...


Detailed Description

The track store an animation of an animated value.

This animation can be interpolated by several ways.

The ITrack and animated value types MUST match else assertions will be raised.

Author:
Cyril 'Hulud' Corvazier , Nevrax France
Date:
2001

Definition at line 58 of file track.h.


Constructor & Destructor Documentation

virtual NL3D::ITrack::~ITrack   [inline, virtual]
 

Virtual destructor.

Definition at line 64 of file track.h.


Member Function Documentation

virtual void NL3D::ITrack::eval const TAnimationTime   date [pure virtual]
 

Evaluation of the value of the track for this time.

The result is internaly stored to simplify access at the polymorphic values. To get the value, call ITrack::getValue().

Implemented in NL3D::ITrackDefault.

Referenced by interpolate.

virtual bool NL3D::ITrack::getLoopMode   const [pure virtual]
 

get LoopMode.

2 mode only: "constant" (<=>false), and "loop" (<=> true). NB: same mode if time < getBeginTIme() and if time > getEndTime()

Implemented in NL3D::ITrackDefault.

virtual const IAnimatedValue& NL3D::ITrack::getValue   const [pure virtual]
 

Get the track current value.

Returns:
the last value evaluated by ITrack::eval().

Implemented in NL3D::CTrackDefaultBlendable.

Referenced by interpolate.

bool NL3D::ITrack::interpolate TAnimationTime    time,
bool &    res
[virtual]
 

Interplation a bool value.

You should be sure that the track you use to interpolate your value is a bool track! An assertion will be raised in debug if the type is wrong.

Parameters:
time  is the time you want the evaluate the value. If time higher than the time gived by getEndTime (), the value returned is the interpolation value at getEndTime (). If time smaller than the time gived by getBeginTime (), the value returned is the interpolation value at getBeginTime ().
res  is the reference on the value to get the result.
Returns:
true if interplation is successful. false if the type asked is wrong.

Implements NL3D::UTrack.

Definition at line 202 of file track.cpp.

References NL3D::CAnimatedValueBool, eval, getValue, NL3D_HAUTO_UTRACK_INTERPOLATE, res, NL3D::TAnimationTime, and value.

bool NL3D::ITrack::interpolate TAnimationTime    time,
std::string &    res
[virtual]
 

Interplation a string value.

You should be sure that the track you use to interpolate your value is a string track! An assertion will be raised in debug if the type is wrong.

Parameters:
time  is the time you want the evaluate the value. If time higher than the time gived by getEndTime (), the value returned is the interpolation value at getEndTime (). If time smaller than the time gived by getBeginTime (), the value returned is the interpolation value at getBeginTime ().
res  is the reference on the value to get the result.
Returns:
true if interplation is successful. false if the type asked is wrong.

Implements NL3D::UTrack.

Definition at line 178 of file track.cpp.

References NL3D::CAnimatedValueString, eval, getValue, NL3D_HAUTO_UTRACK_INTERPOLATE, res, NL3D::TAnimationTime, and value.

bool NL3D::ITrack::interpolate TAnimationTime    time,
NLMISC::CQuat   res
[virtual]
 

Interplation a CQuat value.

You should be sure that the track you use to interpolate your value is a CQuat track! An assertion will be raised in debug if the type is wrong.

Parameters:
time  is the time you want the evaluate the value. If time higher than the time gived by getEndTime (), the value returned is the interpolation value at getEndTime (). If time smaller than the time gived by getBeginTime (), the value returned is the interpolation value at getBeginTime ().
res  is the reference on the value to get the result.
Returns:
true if interplation is successful. false if the type asked is wrong.

Implements NL3D::UTrack.

Definition at line 154 of file track.cpp.

References NL3D::CAnimatedValueQuat, eval, getValue, NL3D_HAUTO_UTRACK_INTERPOLATE, res, NL3D::TAnimationTime, and value.

bool NL3D::ITrack::interpolate TAnimationTime    time,
NLMISC::CVector   res
[virtual]
 

Interplation a CVector value.

You should be sure that the track you use to interpolate your value is a CVector track! An assertion will be raised in debug if the type is wrong.

Parameters:
time  is the time you want the evaluate the value. If time higher than the time gived by getEndTime (), the value returned is the interpolation value at getEndTime (). If time smaller than the time gived by getBeginTime (), the value returned is the interpolation value at getBeginTime ().
res  is the reference on the value to get the result.
Returns:
true if interplation is successful. false if the type asked is wrong.

Implements NL3D::UTrack.

Definition at line 130 of file track.cpp.

References NL3D::CAnimatedValueVector, eval, getValue, NL3D_HAUTO_UTRACK_INTERPOLATE, res, NL3D::TAnimationTime, and value.

bool NL3D::ITrack::interpolate TAnimationTime    time,
NLMISC::CRGBA   res
[virtual]
 

Interplation a CRGBA value.

You should be sure that the track you use to interpolate your value is an CRGBA track! An assertion will be raised in debug if the type is wrong.

Parameters:
time  is the time you want the evaluate the value. If time higher than the time gived by getEndTime (), the value returned is the interpolation value at getEndTime (). If time smaller than the time gived by getBeginTime (), the value returned is the interpolation value at getBeginTime ().
res  is the reference on the value to get the result.
Returns:
true if interplation is successful. false if the type asked is wrong.

Implements NL3D::UTrack.

Definition at line 106 of file track.cpp.

References NL3D::CAnimatedValueRGBA, eval, getValue, NL3D_HAUTO_UTRACK_INTERPOLATE, res, NL3D::TAnimationTime, and value.

bool NL3D::ITrack::interpolate TAnimationTime    time,
sint32   res
[virtual]
 

Interplation an integer value.

You should be sure that the track you use to interpolate your value is an integer track! An assertion will be raised in debug if the type is wrong.

Parameters:
time  is the time you want the evaluate the value. If time higher than the time gived by getEndTime (), the value returned is the interpolation value at getEndTime (). If time smaller than the time gived by getBeginTime (), the value returned is the interpolation value at getBeginTime ().
res  is the reference on the value to get the result.
Returns:
true if interplation is successful. false if the type asked is wrong.

Implements NL3D::UTrack.

Definition at line 82 of file track.cpp.

References NL3D::CAnimatedValueInt, eval, getValue, NL3D_HAUTO_UTRACK_INTERPOLATE, res, NL3D::TAnimationTime, and value.

bool NL3D::ITrack::interpolate TAnimationTime    time,
float &    res
[virtual]
 

Interplation a float value.

You should be sure that the track you use to interpolate your value is a float track! An assertion will be raised in debug if the type is wrong.

Parameters:
time  is the time you want the evaluate the value. If time higher than the time gived by getEndTime (), the value returned is the interpolation value at getEndTime (). If time smaller than the time gived by getBeginTime (), the value returned is the interpolation value at getBeginTime ().
res  is the reference on the value to get the result.
Returns:
true if interplation is successful. false if the type asked is wrong.

Implements NL3D::UTrack.

Definition at line 58 of file track.cpp.

References NL3D::CAnimatedValueFloat, eval, getValue, NL3D_HAUTO_UTRACK_INTERPOLATE, res, NL3D::TAnimationTime, and value.


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