Hello,
i have a Problem with rotating a Bone in a SkinnedMesh.
I determine the current Orientation with getOrientation and writing this values without a modification in a KeyframesSequence, but the bone moves!? Printing out the values shows me that the scalar component changes, but why??? Do they work with degrees or radians ???
Regards,
4had
float[] angleaxis = new float [4];
float[] KF_angleaxis = new float [4];
Obj = myWorld.find(10); // Bone
((Group)Obj).getOrientation(angleaxis);
KF_angleaxis[0] = angleaxis[1];
KF_angleaxis[1] = angleaxis[2];
KF_angleaxis[2] = angleaxis[3];
KF_angleaxis[3] = angleaxis[0];
KeyframeSequence KS = new KeyframeSequence(2, 4, KeyframeSequence.SLERP);
KS.setKeyframe(0, 0, KF_angleaxis);
KS.setKeyframe(1, 500, KF_angleaxis);
KS.setDuration(500);
KS.setValidRange(0, 1);
KS.setRepeatMode(KeyframeSequence.CONSTANT);
AnimationController AC = new AnimationController();
AC.setActiveInterval(0, 500);
AC.setSpeed(2.0f, 0);
AnimationTrack AT = new AnimationTrack(KS, AnimationTrack.ORIENTATION);
AT.setController(AC);
Obj.addAnimationTrack(rotTrack);