osgAnimation.OutCircFunction
是一个实现了 OutCirc 缓动函数的 OpenSceneGraph 动画函数类。
osg::Referenced
osg::AnimationFunction
osgAnimation::OutCircFunction
#include <osgAnimation/OutCircFunction>
OutCircFunction(double duration = 1.0);
OutCircFunction(const OutCircFunction& copy, const osg::CopyOp& copyop = osg::CopyOp::SHALLOW_COPY);
META_Animation(osgAnimation, OutCircFunction)
inline virtual double getValue(double input) const;
OutCircFunction(double duration = 1.0)
:构造函数。
duration
:(可选)动画的时长,默认为 1.0 秒。OutCircFunction(const OutCircFunction& copy, const osg::CopyOp& copyop = osg::CopyOp::SHALLOW_COPY)
:拷贝构造函数。
copy
:要被拷贝的 OutCircFunction 对象。copyop
:(可选)拷贝选项。默认为浅拷贝。inline virtual double getValue(double input) const
:根据输入返回输出值。
input
:输入值。范围为 [0,1] 之间。#include <osgAnimation/OutCircFunction>
osg::ref_ptr<osgAnimation::OutCircFunction> function = new osgAnimation::OutCircFunction(2.0);
double value = function->getValue(0.5); // value = -0.7817459