Author Topic: Proplem with blending pose-animation and skin-animation.  (Read 1126 times)

Offline kiffa

  • long
  • ***
  • Posts: 199
    • View Profile
Proplem with blending pose-animation and skin-animation.
« on: July 25, 2012, 09:53:48 am »
My scene:
 1, Objcets: a rock + a dog
 2, Animations: rock-skin + dog-skin + dog-pose

I want to play all animations at the same time, my codes:

Code: [Select]
           //AnimatedGroup group
            group.animatePose(index, mAnimationIndex);             //dog-pose
            group.animateSkin(index, mAnimationIndex);              //dog-skin
            group.animateSkin(index, mAnimationIndex + 1);        //rock-skin
            group.applyAnimation();

When it run, just play rock-skin and dog-skin, dog-pose didn't be played. But if i changed my code like this(change order):


Code: [Select]
   group.animateSkin(index, mAnimationIndex);          //dog-skin
            group.animatePose(index, mAnimationIndex);         //dong-pose
            group.animateSkin(index, mAnimationIndex + 1);    //rock-skin
            group.applyAnimation();

Rock-skin 、dog-skin、dog-pose are all played.


And if:

 
Code: [Select]
   group.animateSkin(index, mAnimationIndex);          //dog-skin
            group.animateSkin(index, mAnimationIndex + 1);       //rock-skin
            group.animatePose(index, mAnimationIndex);           //dog-pose
            group.applyAnimation();

Dog-pose was played, and rock-skin seems to be played too, but rock-skin was rather different from what seen in maya.

Any advices?


Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1966
    • View Profile
    • http://www.aptalkarga.com
Re: Proplem with blending pose-animation and skin-animation.
« Reply #1 on: July 25, 2012, 08:09:41 pm »
Using pose and skin animation at the same time is called animation blending. from the docs:

Quote
If you need animation blending, you should disable "auto apply animation", first perform pose animation(s) then perform skin animation and finally call applyAnimation().

read the docs ;)