I need to limit the rotation of some bones of my armature. In this image is possible describe better the problem, I used the Limit X option in bone, but the rotation of bones happen in inverse side I want.
The green lines show the correct moviment of bones (what I want to do)…
How i fix it ?
You need to help the IK solver bend in the direction you want by “tipping” the joint opposite to the bend . The way you have it set up it will never bend in the direction you want no matter how you limit the rotation .
It looks like you positioned the bones based on the mesh, and to be honest you seem to want the wrong type of bend for the type of animal this is (wolf ?) . The way you have it now seems the more likely way the joint should bend, and not like what you seem to want (like human legs or a horse’s front legs) …
check this link:
What you need is a pole target for the ik constraint.
Use an empty and position it infront of the knee, then in the Pole Target box type in the name of your target.
Keep in mind the first point stated on that page:
“The IK chain must have an initial rotation in the rest pose, and not just be a straight chain, for this feature to work well.”
As Vertex Pusher said, you need have have the bones slightly bent in the direction you want them to bend with the ik solver.
Don’t worry about editing the mesh. Just move the joint of the armature forwards slightly in edit mode and you should be good.
That said, after a quick google image search for ‘dog running’ I can confirm that what Vertex Pusher said about the direction of the bend being correct already. A dogs front legs do indeed bend ‘backwards’.
Still, adding a Pole target is still a very good idea, it will give you control over the direction in which the joint is pointing, which will at some point during animation need to be adjusted.