About Store Forum Documentation Contact
Donations:
158$/mo



Post Reply 
Conical Rotation Limits for Ragdoll
Author Message
llynx Offline
Member

Post: #1
Conical Rotation Limits for Ragdoll
I've noticed that quite often ragdoll physics results in "awkward" bending and rotation.

Is there a way to implement conical rotation limits between bones in a skeleton?

[I've experimented with dummy ragdoll bones as rotation limiters with moderate success (relatively accurate joint rotation but sometimes results in limbs "floating" above the ground) but still doesn't stop things like 180 degree rotation of a head]
(This post was last modified: 01-09-2011 04:22 AM by llynx.)
01-09-2011 04:00 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: Conical Rotation Limits for Ragdoll
Hi,
What is your naming system for bones? (what names)
01-10-2011 05:19 PM
Find all posts by this user Quote this message in a reply
llynx Offline
Member

Post: #3
RE: Conical Rotation Limits for Ragdoll
   

I have been working with ragdoll bone orientations and can fix the rotation issue based on rotation differences with parent bones, and should be able to work something out to limit the angles bones.

Unless there is a better way of doing this?
(This post was last modified: 01-10-2011 06:37 PM by llynx.)
01-10-2011 06:35 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #4
RE: Conical Rotation Limits for Ragdoll
currently the Ragdoll class creates the joints and sets the angular limits automatically.
it is dependent on the bone names a little.

something like that:

Code:
if(Equal(rb.name,"Head") || Equal(rb.name,"Bip01_Head"))
               {
                  if(Equal(rp.name,"Neck"  ) || Equal(rb.name,"Bip01_Neck"      ))_joints.New().createBodySpherical(rb.actor, rp.actor, sb.pos*_scale, sb.dir, DegToRad(30), DegToRad(35));
                  else                                                            _joints.New().createBodySpherical(rb.actor, rp.actor, sb.pos*_scale, sb.dir, DegToRad(50), DegToRad(40));
               }else
               if(Equal(rb.name,"Neck"     ) || Equal(rb.name,"Bip01_Neck"      ))_joints.New().createBodySpherical(rb.actor, rp.actor, sb.pos*_scale, sb.dir, DegToRad( 20), DegToRad( 5));else
               if(Equal(rb.name,"ShoulderL") || Equal(rb.name,"Bip01_L_Clavicle"))_joints.New().createBodySpherical(rb.actor, rp.actor, sb.pos*_scale, sb.dir, DegToRad(  5), DegToRad( 5));else
               if(Equal(rb.name,"ShoulderR") || Equal(rb.name,"Bip01_R_Clavicle"))_joints.New().createBodySpherical(rb.actor, rp.actor, sb.pos*_scale, sb.dir, DegToRad(  5), DegToRad( 5));else
               if(Equal(rb.name,"ArmLU"    ) || Equal(rb.name,"Bip01_L_UpperArm"))_joints.New().createBodySpherical(rb.actor, rp.actor, sb.pos*_scale, sb.dir, DegToRad( 80), DegToRad(30));else
currently this is built-in and can't be modified
01-10-2011 08:26 PM
Find all posts by this user Quote this message in a reply
llynx Offline
Member

Post: #5
RE: Conical Rotation Limits for Ragdoll
(01-10-2011 08:26 PM)Esenthel Wrote:  currently this is built-in and can't be modified

One of the characters I've modeled needs some fairly tight angular limits so with these fixed constants it won't really help in all situations, (esp when modeling aliens/animals with non-human based joints)

Letting us specify the limits would be useful, but even in the given the standard human mesh/skeleton included (with the standard bone naming scheme) from the EESDK I've seen some crazy bends and twists.

I'll continue my coding until we have more direct control over this.
01-10-2011 10:06 PM
Find all posts by this user Quote this message in a reply
Post Reply