19 #ifndef OSGANIMATION_SAMPLER
20 #define OSGANIMATION_SAMPLER 1
24 #include <osg/Referenced>
25 #include <osg/ref_ptr>
26 #include <osgAnimation/Keyframe>
27 #include <osgAnimation/Interpolator>
90 template<
typename VALUESAMPLERTYPE,
typename TIMESAMPLERTYPE>
93 VALUESAMPLERTYPE& _value;
94 TIMESAMPLERTYPE& _time;
97 typedef typename VALUESAMPLERTYPE::FunctorType::UsingType
UsingType;
98 typedef typename VALUESAMPLERTYPE::FunctorType::KeyframeType
KeyframeType;
104 void getValueAt(
double time,
typename VALUESAMPLERTYPE::FunctorType::UsingType& result)
107 _time.getValueAt(time, newtime);
108 _value.getValueAt(newtime, result);
TemplateSampler< Vec3CubicBezierInterpolator > Vec3CubicBezierSampler
double getEndTime() const
TemplateSampler< Vec3StepInterpolator > Vec3StepSampler
osg::ref_ptr< KeyframeContainerType > _keyframes
TemplateSampler< DoubleLinearInterpolator > DoubleLinearSampler
TemplateSampler< QuatSphericalLinearInterpolator > QuatSphericalLinearSampler
TemplateSampler< Vec4StepInterpolator > Vec4StepSampler
KeyframeContainerType * getOrCreateKeyframeContainer()
double getStartTime() const
TemplateSampler< MatrixLinearInterpolator > MatrixLinearSampler
TemplateSampler< Vec4CubicBezierInterpolator > Vec4CubicBezierSampler
TemplateSampler< Vec2StepInterpolator > Vec2StepSampler
virtual const KeyframeContainer * getKeyframeContainer() const
TemplateCompositeSampler(VALUESAMPLERTYPE &value, TIMESAMPLERTYPE &time)
VALUESAMPLERTYPE::FunctorType::KeyframeType KeyframeType
TemplateSampler< FloatStepInterpolator > FloatStepSampler
TemplateSampler< Vec2LinearInterpolator > Vec2LinearSampler
KeyframeContainerType * getKeyframeContainerTyped()
void setKeyframeContainer(KeyframeContainerType *kf)
VALUESAMPLERTYPE::FunctorType::UsingType UsingType
TemplateKeyframeContainer< KeyframeType > KeyframeContainerType
TemplateSampler< Vec3LinearInterpolator > Vec3LinearSampler
TemplateSampler< DoubleCubicBezierInterpolator > DoubleCubicBezierSampler
TemplateSampler< Vec2CubicBezierInterpolator > Vec2CubicBezierSampler
TemplateSampler< FloatCubicBezierInterpolator > FloatCubicBezierSampler
TemplateSampler< DoubleStepInterpolator > DoubleStepSampler
float getStartTime() const
const KeyframeContainerType * getKeyframeContainerTyped() const
TemplateSampler< FloatLinearInterpolator > FloatLinearSampler
virtual KeyframeContainer * getKeyframeContainer()
F::KeyframeType KeyframeType
void getValueAt(double time, UsingType &result) const
virtual KeyframeContainer * getKeyframeContainer()=0
TemplateSampler< QuatStepInterpolator > QuatStepSampler
TemplateSampler< Vec4LinearInterpolator > Vec4LinearSampler
void getValueAt(double time, typename VALUESAMPLERTYPE::FunctorType::UsingType &result)