How to switch animation in D3D?

Started by
3 comments, last by lucky6969b 12 years, 5 months ago

m_pAnimCtrl->SetTrackDesc(...);


Do I use this function to switch animation in Direct3D?
What I'd like to do is to have an animation played back when a NPC gets close to another object within a certain threshold. It would be replayed again when it gets close to yet another similar object, and this cycle runs over and over again until the program stops.
This animation is stored with D3DXCreateKeyFramedAnimationSet, I am hoping that I can reuse that as well.
Any suggestions? just briefly is okay
Thanks
Jack
Advertisement
Just a guts feeling, do I have to restart the animation controller?(Resetting time to zero each time I introduce a new animation sequence)? Thanks Jack
I wonder what method should I take in the following scenario? A racking system has 4 different height levels, the forklift has to reach each of them at different times. What I am currently doing is storing a generated animation set in the controller, and "fire" an animation start event when they are close enough.... What are your suggestions? Thanks Jack


m_pAnimCtrl->SetTrackDesc(...);


Do I use this function to switch animation in Direct3D?
What I'd like to do is to have an animation played back when a NPC gets close to another object within a certain threshold. It would be replayed again when it gets close to yet another similar object, and this cycle runs over and over again until the program stops.
This animation is stored with D3DXCreateKeyFramedAnimationSet, I am hoping that I can reuse that as well.
Any suggestions? just briefly is okay
Thanks
Jack


Use SetTrackAnimationSet.

If you're interested, google "Skinned Mesh Character Animation with Direct3D 9.0c". It's an article by Frank Luna that explains animation well.
"Spending your life waiting for the messiah to come save the world is like waiting around for the straight piece to come in Tetris...even if it comes, by that time you've accumulated a mountain of shit so high that you're fucked no matter what you do. "
Thanks Waaayoff, you just remind me of that article. Jack

This topic is closed to new replies.

Advertisement