- Home /
OpenNI Zigfu Kinect problem
Im having a problem with the models legs when using zigfu.
They rotate backwards from time to time with no apparent reason. If i move my knees forward it fixed the problem for a while and then rotates backwards again.
It happens with every model i try, including the one that comes with the project.
Any help solving this?
Answer by Jerdak · Aug 07, 2012 at 06:46 PM
I've not used ZigFu but your problem sounds like a common issue that comes from deriving joint rotations from the vectors formed by said joints. For example if I use neck->shoulder and shoulder->elbow to find the the shoulder angle and the angle isn't signed, my arm will flip directions whenever the elbow joint crosses the Y/Z plane.
Nothing in the ZigFU SDK suggests they use any sort of inverse kinematics to drive their animation so you should be able to see this problem by dumping the orientation of the joint connecting the leg to the body. If that turns out to be the problem you can try digging in to their angle calculations. If you can't do anything in their code, try setting thresholds on certain joints. Like the forcing the knee joint to always be N millimeters further "foward" from the hip joint.