GlsAnimation Library
1.0.6
Provides classes and functions to support animating GL Studio objects programmatically or with script files
|
Class template for keyframe curves of different types (double, Vector, etc.) More...
#include <gls_keyframe.h>
Public Types | |
typedef stdortr1::shared_ptr< GlsKeyframeCurve > | Ptr |
Alias for easier reading. | |
typedef stdortr1::shared_ptr< const GlsKeyframeCurve > | PtrConst |
Alias for easier reading. | |
typedef T | Value |
The templated type. | |
typedef Detail::DefaultInterpolator< Value >::Type | DefaultInterpolator |
The default interpolator for the given Value type. | |
Public Types inherited from disti::GlsKeyframeCurveBase | |
typedef double | Key |
The key type (usually time, but not always) | |
typedef std::size_t | Size |
The size type for sizes and indices. | |
typedef std::pair< Key, Key > | KeyPair |
Alias for easier reading. | |
Public Member Functions | |
GlsKeyframeCurve (const GlsKeyframeInterpolator< Value > *const interpolator=new DefaultInterpolator()) | |
GlsKeyframeCurve (typename GlsKeyframeInterpolator< Value >::PtrConst interpolator) | |
Size | GetKeyframeCount () const |
Override from GlsKeyframeCurveBase. | |
KeyPair | GetMinMaxKeys () const |
Override from GlsKeyframeCurveBase. | |
void | AddKeyframe (const Key &key, const Value &value, const Key &tolerance=Detail::g_glsAnimationFloatTolerance) |
Value | Interpolate (const Key &key) const |
Public Member Functions inherited from disti::GlsKeyframeCurveBase | |
virtual | ~GlsKeyframeCurveBase () |
Destructor. | |
Class template for keyframe curves of different types (double, Vector, etc.)
|
inlineexplicit |
Constructor
interpolator | An interpolating functor. The curve takes ownership of the functor. If unspecified, the curve defaults to a linear interpolator, except for string types where it defaults to a gated interpolator. |
|
inlineexplicit |
Constructor
interpolator | An interpolating functor. The interpolator has shared ownership and can be used by multiple curves. |
|
inline |
Add the specified keyframe the sorted list.
key | The key (often time, sometimes some other units) for the curve. |
value | The value at the location of the given key. |
tolerance | The tolerance for comparing floating-point keys to be equal. |
|
inline |
Interpolates the keyframes at the specified value.
key | The key to be interpolated in between keyframes. |