Basic point to point joints are simple to implement, as explained in Witkin/Baraff siggraph course notes & Chris Hecker's ponytail demo.
However, how to I implement more complicated joints, like hinge joints? (For example, in hinge joints, what is the constraint force to be applied that causes the two bodies rotations to be lined up? -- I want to use something better than just throwing in 2 point-point constraints).
Thanks!
How to implement joints (like hinge joints).
-
- Posts: 231
- Joined: Tue Feb 20, 2007 4:56 pm
Re: How to implement joints (like hinge joints).
Well you've got one axis (the hinge axis) where the two bodies are allowed to rotate around each other freely. Since it is Free and it's like an Axle, we shall call it Axel F. Then you can take any two axes (let's call them A1 and A2) orthogonal to Axel F and to each other and prevent them from moving relative to each other, eliminating 2 DOFs.
So your Jacobian for those 2 angular DOFs is:
[0 A1 0 -A1]
[0 A2 0 -A2]
If you add your 3-DOF "point-to-point" constraint (more commonly known as a ball joint), it will act like a full 5-DOF hinge.
So your Jacobian for those 2 angular DOFs is:
[0 A1 0 -A1]
[0 A2 0 -A2]
If you add your 3-DOF "point-to-point" constraint (more commonly known as a ball joint), it will act like a full 5-DOF hinge.