本文整理汇总了C++中LLMotion::isBlending方法的典型用法代码示例。如果您正苦于以下问题:C++ LLMotion::isBlending方法的具体用法?C++ LLMotion::isBlending怎么用?C++ LLMotion::isBlending使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LLMotion
的用法示例。
在下文中一共展示了LLMotion::isBlending方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: startMotion
//-----------------------------------------------------------------------------
// startMotion()
//-----------------------------------------------------------------------------
BOOL LLMotionController::startMotion(const LLUUID &id, F32 start_offset)
{
// do we have an instance of this motion for this character?
LLMotion *motion = findMotion(id);
// motion that is stopping will be allowed to stop but
// replaced by a new instance of that motion
if (motion
&& !mPaused
&& motion->canDeprecate()
&& motion->isActive() // singu: do not deprecate motions that are not active.
&& motion->getFadeWeight() > 0.01f // not LOD-ed out
&& (motion->isBlending() || motion->getStopTime() != 0.f))
{
deprecateMotionInstance(motion);
// force creation of new instance
motion = NULL;
}
// create new motion instance
if (!motion)
{
motion = createMotion(id);
}
if (!motion)
{
return FALSE;
}
//if the motion is already active and allows deprecation, then let it keep playing
else if (motion->canDeprecate() && isMotionActive(motion))
{
return TRUE;
}
// llinfos << "Starting motion " << name << llendl;
//<singu>
F32 start_time = mAnimTime - start_offset;
if (!mDisableSyncing)
{
start_time = motion->syncActivationTime(start_time);
}
++mDisableSyncing;
//</singu>
BOOL res = activateMotionInstance(motion, start_time);
//<singu>
--mDisableSyncing;
//</singu>
return res;
}