GeekAntic
Member
|
Inverse Kinematics
The engine is a really kewl piece of work.
You stated that the engine is also able to handle inverse Kinematics. I ve downloaded BM to investigate that feature. I was not able to find another part then that:
Code:
if(inv.slot[SLOT_ARM_L].valid()) // if has item in left hand
if(OrientP *point=cskel.findPoint("HandL"))
{
Vec current_dir=-point->cross(); // this is the current weapon direction in world space
Matrix3 transform; transform.setRotation(current_dir,desired_dir,b_aim_l); // create matrix which transforms current direction into desired direction
cskel.transformInWorldSpace(sac.arm_lu,transform); // call this method to perform a world space transformation
}
I wonder if there is a real ik example. I am thinking of bonechains, joint frition, prefered angles and angle restriction.
Have to say it again, great work!
|
|
12-10-2009 10:36 PM |
|
GeekAntic
Member
|
RE: Inverse Kinematics
so the ik api are the function of cskel.transformInWorldSpace and bonechain solving is implemented?
I will figure out how it works if you give me enough information about the right starting point.
IK solving is a key feature i need for my current project.
|
|
12-11-2009 09:27 AM |
|
Esenthel
Administrator
|
RE: Inverse Kinematics
you can achieve bonechain for 2 bones using transformInWorldSpace and some math
|
|
12-11-2009 03:52 PM |
|
GeekAntic
Member
|
RE: Inverse Kinematics
Hm, so its no real IK. Its more or less FK?
|
|
12-11-2009 06:44 PM |
|
Esenthel
Administrator
|
RE: Inverse Kinematics
no, FK is done just by animating, with "transformInWorldSpace and some math" you can do IK, for example on 2 bones, like full arm
|
|
12-11-2009 07:29 PM |
|