Jump to content
Hash, Inc. Forums

Train Wheel Rig


pixmite

Recommended Posts

The Train Wheel Rig – An alternative method for and elbow / knee joints

 

Updated 11/15/12 with missing model file

 

I came up with something that I though I’d share with the rest to you. The problem I wanted to solve was that the methods for rigging a joint like an elbow that I’ve tried (Fan Bones, CP weighting) all result in a collapsing geometry at the site of the joint. Then I'd have go back and repair the geometry with oodles of smart skin especially when I have a char with thick / muscular joints that have CPs far from the bicep / wrist bones to begin with. So here’s what I came up with:

 

The Elbow / Knee Type Rig:

 

Using an elbow as an example, I have created two pairs of bones that govern the movement of the geometry at the joint. One set for the top and another for the bottom. Each pair is made up of a bone that orients like the wrist bone as it bends at the elbow. I call this bone “Wrist Skin Top / Bottom.” This bone is attached to a bone that traverses parallel to the “Bicep” bone which I call “Bicep Skin Top / Bottom.”

 

figure1.jpg

 

The secret sauce is in the hidden bones that govern / constrain the “Bicep Skin Top / Bottom” bones. I call these bones “Riders” because they take a ride with the wrist bone as it moves. One Rider bone creates the lateral movement for the “Bicep Skin Top” bone and the other for the “Bicep Skin Bottom” bone. This is accomplished with a “Translate To” constraint to the Wrist Bone. When you observe these bones in motion as you move the wrist, it kinda looks like old Choo-Choo train wheel, hence the discriptive, if unimaginative name for the rig.

 

figure2.jpg

 

I place one more constraint on the “Bicep Skin Top / Bottom” bones so that they don’t inherit the perpendicular movement of the “Rider” bones and I get exactly what I was looking for. Now all I have to do is share the CPs weights between the 6 bones (Bicep, Wrist, Bicep Skin Top / Bottom, Wrist Skin Top / Bottom) and I have an elbow join that can move through its entire range of motion without the geometry collapsing and absolutely no smart skin work repairs, Yeah!

 

Movie1.jpg

 

Here's the project and Model files:

 

ArmBoneTest.prj

ArmBoneTest.mdl

 

Some important factoids:

  • The positioning of the Rider bones is the key the whole rig. You’ll want to place them so that one is directly on top of the “Bicep” bone and the other the “Wrist” bone. Their roots are placed at the edge of an imaginary circle drawn around the center of the joint whose diameter is equal to the thickness of the geometry. (This assumes that the joint has been placed at the center of the geometry).
  • Since the “Rider” bones derive their translational movement from a circle, they create a natural ease in / ease out for the “Bicep Skin Top / Bottom” bones.
  • The rig will work for bending the wrist well past the 90 Deg point, but completely breakdown if you bend it the other direction. i.e. hyperextend the elbow.

Well that’s spiffy you say, but it won’t help me with a Wrist / Hand Joint. True, not in its current form, but if we spit the motion into 2 halves, one for each direction and constrain the skin bones to both accordingly, we can make it work. But first may suggest an adult beverage, it gets a bit boney ahead ;)

 

The Wrist / Hand Type of Rig:

 

In short we need to double up the rig to create two separate lateral movements for our “Wrist Skin” bones. First thing we do here is to create two bones that sit directly on top of our hand bone with the same root location. They are then constrained to “Orient Like” the “Hand” bone but limited to half their range of motion. One will only mimic the hand movement upwards and the other only downwards.

 

figure3.jpg

 

Now we create two sets of “Rider” bones, one for each direction of the hand (up / down). These are placed on top of our “Wrist” and “Hand” bones respectively, but this time at twice the radius of our imaginary circle that touches the limits of our geometry. Ok, take another drink - This is because we will be using the sum of only half their movement to govern the “Skin” bones. The Riders are then given their “Translate To” constraints to the hand.

 

figure4.jpg

 

Lastly, we constraint the “Wrist Top / Bottom Skin” bones to the two corresponding Riders so as well as eliminate their perpendicular movement. Add the “Orient Like” constraint to the “Hand Skin Top / Bottom” bones and we’re done.

 

Movie2.jpg

 

And the model file:

 

Wrist_Experiment3_With_SmartSkin.prj

 

Some important factoids about this rig:

  • It only works for the range of motion of the “Hand” bone from 89.99 Deg through -90 Deg. I’m assuming that this is software limitation, i.e. up to but not including kind of thing.
  • Once again the circular motion provides us with a natural ease in ease out in both directions.
  • I did need a bit of smart skin in the end, but I only needed to apply it at the two extremes and only a small amount to make it look natural. I tried to fix this by playing with the enforcement channel of the “Translate To” constraint of the “Wrist Skin Top / Bottom” bones, but couldn’t get it to work. I wanted to try to slow the movement a bit as it neared the extremes. I’m not well skilled with channel editing. No change I made seemed to have an impact. Maybe it was the fact that is was an on/off type pose?

Try it out and tell me what you think. Please feel free to poke holes in it or suggest changes. Thanks in advance for any wisdom you can provide and happy animating ;)

 

Pixmite

 

(Link to Matt's 1MB video)

Link to comment
Share on other sites

  • Admin
The Train Wheel Rig – An alternative method for and elbow / knee joints

 

Too cool!

I like what I'm seeing here especially because I like to have full control over all deformations.

 

I made a movie, but it wouldnot let me up load the file - it was probably to big

 

Size should not be an issue with uploading movies unless the size is huge so I shouldn't think that would be a problem for you.

The main constraint I know of before was that we couldn't upload AVI files. (I think we fixed that though)

 

If you can tell me more about the file you were trying to upload that should solve that.

 

 

I'm reading up on everything you've written now. Thanks!

It reminds me of some Cog solutions I've seen in the past but I'm liking your approach.

Link to comment
Share on other sites

Size should not be an issue with uploading movies unless the size is huge so I shouldn't think that would be a problem for you.

The main constraint I know of before was that we couldn't upload AVI files. (I think we fixed that though)

 

If you can tell me more about the file you were trying to upload that should solve that.

 

I was having some problems with rendering errors. Got that sorted out, but the file type is AVI and they are large. Unfortunately I do not have a tool of any kind to compress them. Can you suggest one?

Link to comment
Share on other sites

You could set this up using expressions and not use all the control bones and constraints.

 

Also, your first project has no model in it. In your second project, your model is still using smartskin.

 

It is an interesting concept, but if you can't rotate past 90', it not practical.

Link to comment
Share on other sites

You could set this up using expressions and not use all the control bones and constraints.

 

Also, your first project has no model in it. In your second project, your model is still using smartskin.

 

It is an interesting concept, but if you can't rotate past 90', it not practical.

 

I supose you could do it all with expressions, however it might get a bit mathy rather than boney ;)

 

I also verified the download of the first project file myself. I does indeed contain a model called "ArmBone Test" which does rotate wonderfully well past the 90 deg mark, to about 120 deg before it begins to deteriate. See the 3rd picture of the orginal post.

 

As for the second file, yes I applied a little touch up smart skin at the extreme. It about 90% less smart skin than I would normally apply to any other rig type that I've tried, so I'm quite happy with it, but thank you for your comments. I may try an expresion version to see if might be easier in the long run.

 

Here's a shot of the 2nd file / model with no smart skin applied. It still does pretty well even without it.

 

figure5.jpg

Link to comment
Share on other sites

It only works for the range of motion of the “Hand” bone from 89.99 Deg through -90 Deg. I’m assuming that this is software limitation, i.e. up to but not including kind of thing.

 

Here's his quote. This is for the second project that he posted. And since his first project does not have the model embedded, I can't doing any testing.

Link to comment
Share on other sites

  • Admin

I would think you'd want the Bicep Skin Top and Bicep Skin Bottom Bones to be children of the Bicep Bone otherwise there is going to be problems.

Disregard if that is obvious and your setup was simply not concerned with demo'ing that.

There also may be something I'm not considering here with regard to the setup.

Link to comment
Share on other sites

I would think you'd want the Bicep Skin Top and Bicep Skin Bottom Bones to be children of the Bicep Bone otherwise there is going to be problems.

Disregard if that is obvious and your setup was simply not concerned with demo'ing that.

There also may be something I'm not considering here with regard to the setup.

 

Children of the bicep bone. Hmm that could be somthing I overlooked, but I think that you could still set up the same constraints with them being children. When I was testing I did not factor that into it. Was the question spawned over concern of using a standard rig?

Link to comment
Share on other sites

It only works for the range of motion of the “Hand” bone from 89.99 Deg through -90 Deg. I’m assuming that this is software limitation, i.e. up to but not including kind of thing.

 

Here's his quote. This is for the second project that he posted. And since his first project does not have the model embedded, I can't doing any testing.

 

I've added the missing model file to the original post. You also intrigued me with the expression suggestion. I think I'm going to give it a try.

Link to comment
Share on other sites

It only works for the range of motion of the “Hand” bone from 89.99 Deg through -90 Deg. I’m assuming that this is software limitation, i.e. up to but not including kind of thing.

 

Here's his quote. This is for the second project that he posted. And since his first project does not have the model embedded, I can't doing any testing.

 

I've added the missing model file to the original post. You also intrigued me with the expression suggestion. I think I'm going to give it a try.

 

And here is the Result. I've taken the training wheels off and replaced them with 2 expressions. To preserve the ease in / ease out I had to break the movement into 4 separate sections each leveraging the Cosine function to get the curve.

Hand bone rotations from: -180 to -90, -90 to 0, 0, to 90 and 90 to 180. Then I had to multiply it by a constant (2.45) to scale it to my geometry. The formula is messy but it works.

 

Wrist skin top’s horizontal movement now looks like this:

 

If(..|..|..|..|Hand.Transform.Rotate.X>0,(If(..|..|..|..|Hand.Transform.Rotate.X-90,(Cos(Radians(..|..|..|..|Hand.Transform.Rotate.X*2))-1)*-2.45,(Cos(Radians(..|..|..|..|Hand.Transform.Rotate.X*2))+3)*2.45))

 

Wrist skin bottom’s movement is the opposite and looks like this:

 

If(..|..|..|..|Hand.Transform.Rotate.X>0,(If(..|..|..|..|Hand.Transform.Rotate.X-90,(Cos(Radians(..|..|..|..|Hand.Transform.Rotate.X*2))-1)*2.45,(Cos(Radians(..|..|..|..|Hand.Transform.Rotate.X*2))+3)*-2.45))

 

Note that once the bone is bent past about 120 deg, both positively and negatively, the formula begins to fail us. Since the movement broken into 4 separate sections we can replace the Cos function during that phase of movement with something that would increase the horizontal rate like a, X^2 or X^3 curve, where X is some normalized amount of the current rotation angle of the hand bone between -90 to -180 and 90 to 180. I’ll work on that for my next post. Ok now I need a drink ;)

 

Hand_Formula.prj

Link to comment
Share on other sites

Ok Here's the next generation. I still needs a bit of work to smooth out the transitions between the formulas, but I'm quite happy with the result. It looks like a pretty realistic elbow up to about 140 deg of bend. The model has no smart skin, only control point weighting.

 

Formula1.jpg

 

A short movie...

 

Movie3.mp4.mp4

 

And the project file...

 

Hand_Formula2.prj

Link to comment
Share on other sites

  • 2 months later...
The Train Wheel Rig – An alternative method for and elbow / knee joints

 

Updated 11/15/12 with missing model file

 

I came up with something that I though I’d share with the rest to you. The problem I wanted to solve was that the methods for rigging a joint like an elbow that I’ve tried (Fan Bones, CP weighting) all result in a collapsing geometry at the site of the joint. Then I'd have go back and repair the geometry with oodles of smart skin especially when I have a char with thick / muscular joints that have CPs far from the bicep / wrist bones to begin with. So here’s what I came up with:

 

The Elbow / Knee Type Rig:

 

Using an elbow as an example, I have created two pairs of bones that govern the movement of the geometry at the joint. One set for the top and another for the bottom. Each pair is made up of a bone that orients like the wrist bone as it bends at the elbow. I call this bone “Wrist Skin Top / Bottom.” This bone is attached to a bone that traverses parallel to the “Bicep” bone which I call “Bicep Skin Top / Bottom.”

 

figure1.jpg

 

The secret sauce is in the hidden bones that govern / constrain the “Bicep Skin Top / Bottom” bones. I call these bones “Riders” because they take a ride with the wrist bone as it moves. One Rider bone creates the lateral movement for the “Bicep Skin Top” bone and the other for the “Bicep Skin Bottom” bone. This is accomplished with a “Translate To” constraint to the Wrist Bone. When you observe these bones in motion as you move the wrist, it kinda looks like old Choo-Choo train wheel, hence the discriptive, if unimaginative name for the rig.

 

figure2.jpg

 

I place one more constraint on the “Bicep Skin Top / Bottom” bones so that they don’t inherit the perpendicular movement of the “Rider” bones and I get exactly what I was looking for. Now all I have to do is share the CPs weights between the 6 bones (Bicep, Wrist, Bicep Skin Top / Bottom, Wrist Skin Top / Bottom) and I have an elbow join that can move through its entire range of motion without the geometry collapsing and absolutely no smart skin work repairs, Yeah!

 

Movie1.jpg

 

Here's the project and Model files:

 

ArmBoneTest.prj

ArmBoneTest.mdl

 

Some important factoids:

  • The positioning of the Rider bones is the key the whole rig. You’ll want to place them so that one is directly on top of the “Bicep” bone and the other the “Wrist” bone. Their roots are placed at the edge of an imaginary circle drawn around the center of the joint whose diameter is equal to the thickness of the geometry. (This assumes that the joint has been placed at the center of the geometry).
  • Since the “Rider” bones derive their translational movement from a circle, they create a natural ease in / ease out for the “Bicep Skin Top / Bottom” bones.
  • The rig will work for bending the wrist well past the 90 Deg point, but completely breakdown if you bend it the other direction. i.e. hyperextend the elbow.

Well that’s spiffy you say, but it won’t help me with a Wrist / Hand Joint. True, not in its current form, but if we spit the motion into 2 halves, one for each direction and constrain the skin bones to both accordingly, we can make it work. But first may suggest an adult beverage, it gets a bit boney ahead ;)

 

The Wrist / Hand Type of Rig:

 

In short we need to double up the rig to create two separate lateral movements for our “Wrist Skin” bones. First thing we do here is to create two bones that sit directly on top of our hand bone with the same root location. They are then constrained to “Orient Like” the “Hand” bone but limited to half their range of motion. One will only mimic the hand movement upwards and the other only downwards.

 

figure3.jpg

 

Now we create two sets of “Rider” bones, one for each direction of the hand (up / down). These are placed on top of our “Wrist” and “Hand” bones respectively, but this time at twice the radius of our imaginary circle that touches the limits of our geometry. Ok, take another drink - This is because we will be using the sum of only half their movement to govern the “Skin” bones. The Riders are then given their “Translate To” constraints to the hand.

 

figure4.jpg

 

Lastly, we constraint the “Wrist Top / Bottom Skin” bones to the two corresponding Riders so as well as eliminate their perpendicular movement. Add the “Orient Like” constraint to the “Hand Skin Top / Bottom” bones and we’re done.

 

Movie2.jpg

 

And the model file:

 

Wrist_Experiment3_With_SmartSkin.prj

 

Some important factoids about this rig:

  • It only works for the range of motion of the “Hand” bone from 89.99 Deg through -90 Deg. I’m assuming that this is software limitation, i.e. up to but not including kind of thing.
  • Once again the circular motion provides us with a natural ease in ease out in both directions.
  • I did need a bit of smart skin in the end, but I only needed to apply it at the two extremes and only a small amount to make it look natural. I tried to fix this by playing with the enforcement channel of the “Translate To” constraint of the “Wrist Skin Top / Bottom” bones, but couldn’t get it to work. I wanted to try to slow the movement a bit as it neared the extremes. I’m not well skilled with channel editing. No change I made seemed to have an impact. Maybe it was the fact that is was an on/off type pose?

Try it out and tell me what you think. Please feel free to poke holes in it or suggest changes. Thanks in advance for any wisdom you can provide and happy animating ;)

 

Pixmite

 

(Link to Matt's 1MB video)

Well, I think its interesting for sure but I don't think the extreme position of the bend, in your later videos will cut it. Its sort of doing the opposite of what a joint would do, and that is pinch together inside the bend instead of somehow sliding out away from the joint.

 

as far as advice, keep tinkering! I have not used smartskin in one of my models ever. between fans/cogs (yeah I said that) and control point weighting and smartskin there are a lot of different ways to skin our cats. I remember I was working on a bone that would slide down the length of the bone(via expressions) and pull the joint setup bones away from the center to give more room for the geometry to bend and squish in itself and worked good but not as well as fans and cogs.

 

Mike Fitz

www.3dartz.com

Link to comment
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...