Jump to content
  • Advertisement
Sign in to follow this  

Skin Mesh Tracks Animation

This topic is 4483 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Here is my code for setting the Animation with the respective tracks
Desc.Enable = true;
Desc.Speed = 1;
Desc.Weight = 0.0;
Desc.Position = 0;
Desc.Priority = D3DXPRIORITY_HIGH;

for (UINT n=0; n<AnimController->GetNumAnimationSets(); n++)
    AnimController->SetTrackDesc(n, &Desc);
    AnimController->GetAnimationSet(n, &AnimationSet);
    AnimController->SetTrackAnimationSet(n, AnimationSet);

//To set the track's weight, for example to use track 2
Mesh.GetAnimController()->SetTrackWeight(2, 1.0f);
It can't run the animation that is place at track 2, i used the tiny_4anim.x model that come with the dec_sdk. Only track 0, and 1 seems to be able to work. am i doing anything wrongly?

Share this post

Link to post
Share on other sites
The AnimationController created by DirectX when you load the tiny_4anim.x file only supports a max of 2 animation tracks. You can play one at a time or blend a max of 2 at a time. So, to play more than two, you need to reassign track 0 or 1 to the other animation sets.

Share this post

Link to post
Share on other sites
You can create your own animation controller with an arbitrary number of tracks, although performance may go down.

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!