diff options
Diffstat (limited to 'indra/llcharacter/llkeyframemotion.cpp')
| -rw-r--r-- | indra/llcharacter/llkeyframemotion.cpp | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/indra/llcharacter/llkeyframemotion.cpp b/indra/llcharacter/llkeyframemotion.cpp index 16a0e71f04..d8a4acecc1 100644 --- a/indra/llcharacter/llkeyframemotion.cpp +++ b/indra/llcharacter/llkeyframemotion.cpp @@ -405,15 +405,17 @@ void LLKeyframeMotion::JointMotion::update(LLJointState* joint_state, F32 time, // LLKeyframeMotion() // Class Constructor //----------------------------------------------------------------------------- -LLKeyframeMotion::LLKeyframeMotion( const LLUUID &id) : LLMotion(id) +LLKeyframeMotion::LLKeyframeMotion(const LLUUID &id) + : LLMotion(id), + mJointMotionList(NULL), + mJointStates(NULL), + mPelvisp(NULL), + mLastSkeletonSerialNum(0), + mLastUpdateTime(0.f), + mLastLoopedTime(0.f), + mAssetStatus(ASSET_UNDEFINED) { - mJointMotionList = NULL; - mJointStates = NULL; - mLastSkeletonSerialNum = 0; - mLastLoopedTime = 0.f; - mLastUpdateTime = 0.f; - mAssetStatus = ASSET_UNDEFINED; - mPelvisp = NULL; + } @@ -1718,7 +1720,7 @@ BOOL LLKeyframeMotion::serialize(LLDataPacker& dp) const } success &= dp.packS32(mJointMotionList->mConstraints.size(), "num_constraints"); - for (JointMotionList::constraint_list_t::iterator iter = mJointMotionList->mConstraints.begin(); + for (JointMotionList::constraint_list_t::const_iterator iter = mJointMotionList->mConstraints.begin(); iter != mJointMotionList->mConstraints.end(); ++iter) { JointConstraintSharedData* shared_constraintp = *iter; @@ -1836,8 +1838,7 @@ void LLKeyframeMotion::setEaseOut(F32 ease_in) //----------------------------------------------------------------------------- void LLKeyframeMotion::flushKeyframeCache() { - // TODO: Make this safe to do -// LLKeyframeDataCache::clear(); + LLKeyframeDataCache::clear(); } //----------------------------------------------------------------------------- @@ -1913,7 +1914,7 @@ void LLKeyframeMotion::setLoopOut(F32 out_point) void LLKeyframeMotion::onLoadComplete(LLVFS *vfs, const LLUUID& asset_uuid, LLAssetType::EType type, - void* user_data, S32 status) + void* user_data, S32 status, LLExtStat ext_status) { LLUUID* id = (LLUUID*)user_data; @@ -2091,7 +2092,6 @@ void LLKeyframeDataCache::removeKeyframeData(const LLUUID& id) keyframe_data_map_t::iterator found_data = sKeyframeDataMap.find(id); if (found_data != sKeyframeDataMap.end()) { - delete found_data->second; sKeyframeDataMap.erase(found_data); } } @@ -2122,7 +2122,6 @@ LLKeyframeDataCache::~LLKeyframeDataCache() //----------------------------------------------------------------------------- void LLKeyframeDataCache::clear() { - for_each(sKeyframeDataMap.begin(), sKeyframeDataMap.end(), DeletePairedPointer()); sKeyframeDataMap.clear(); } |
