The following isn't working.
animatedGroup.animateSkin(0.04f, IDLE);
animatedGroup.applyAnimation();
idlePose = animatedGroup.get(0).getSkeletonPose().clone();
idlePose.setToBindPose();//NOT SURE IF THIS IS NEEDED. JUST TRYING
idlePose.updateTransforms();//NOT SURE IF THIS IS NEEDED. JUST TRYING
animatedGroup.animateSkin(0.04f, WALKS);
animatedGroup.applyAnimation();
walkingPose = animatedGroup.get(0).getSkeletonPose().clone();
walkingPose.setToBindPose();//NOT SURE IF THIS IS NEEDED. JUST TRYING
walkingPose.updateTransforms();//NOT SURE IF THIS IS NEEDED. JUST TRYING
Then, in the game loop:
SkeletonPose pose = SkeletonHelper.interpolateSkeletonPose(idlePose, walkingPose, skinFrame+=deltaTime);
animatedGroup.setSkeletonPose(pose);
pose.updateTransforms();
animatedGroup.applySkeletonPose();
if (skinFrame >= 1.00f)
//SWITCH TO SECOND ANIMATION
What I get is the character in his static pose during the entire interpolation time (at the end of which, obviously, he switches to the second animation successfully). So, what should I be doing differently?