- renamed "bone" anims and associated structures to generic "node" anims. Breaking change, sorry for that.

git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@166 67173fc5-114c-0410-ac8e-9d2fd5bffc1f
This commit is contained in:
ulfjorensen
2008-09-30 13:05:48 +00:00
parent 832f9cf672
commit 8925813026
15 changed files with 140 additions and 145 deletions

View File

@@ -535,10 +535,10 @@ void SMDImporter::CreateOutputAnimations()
aiAnimation*& anim = this->pScene->mAnimations[0] = new aiAnimation();
anim->mDuration = this->dLengthOfAnim;
anim->mNumBones = iNumBones;
anim->mNumChannels = iNumBones;
anim->mTicksPerSecond = 25.0; // FIXME: is this correct?
aiBoneAnim** pp = anim->mBones = new aiBoneAnim*[anim->mNumBones];
aiNodeAnim** pp = anim->mChannels = new aiNodeAnim*[anim->mNumChannels];
// now build valid keys
unsigned int a = 0;
@@ -548,12 +548,10 @@ void SMDImporter::CreateOutputAnimations()
{
if (!(*i).bIsUsed)continue;
aiBoneAnim* p = pp[a] = new aiBoneAnim();
aiNodeAnim* p = pp[a] = new aiNodeAnim();
// copy the name of the bone
p->mBoneName.length = (*i).mName.length();
::memcpy(p->mBoneName.data,(*i).mName.c_str(),p->mBoneName.length);
p->mBoneName.data[p->mBoneName.length] = '\0';
p->mNodeName.Set( i->mName);
p->mNumRotationKeys = (unsigned int) (*i).sAnim.asKeys.size();
if (p->mNumRotationKeys)