PDA

View Full Version : How to Create a Realistic Chain...?



jaketapia
12-09-2004, 06:06 PM
Hi All,

I am starting a animation project for a company and in this animation I have to animate a character pulling on metal chain. The problem I am having is animating the chain realistically. I have tried using a 2 point poly chain, Cloth_FX, and Hard_link and that works...kind of. The main problem with that is that the chain links don't stay within each other. Does anyone know how to accomplish this? Thanks in advance.

Jake

Silkrooster
12-09-2004, 07:11 PM
Depending on the length of your chain, you could use bones and set joint limits to keep the links from bending to far.
Silk

Thomas M.
12-10-2004, 03:11 AM
You're on the right track. Just make sure the spring value is really low (1) and the stretch limit even lower (0.1>). Take care the points of the poly chain are in the section where both chain elements touch each other. Should work fine.

jaketapia
12-10-2004, 08:06 AM
Thanks Silk for the alternate idea, and thanks Thomas for the tips. I'll try it out ASAP!

SplineGod
12-11-2004, 03:39 AM
Do both.
Create a string of 2 point polys where each point corresponds to each link of your chain. Run the make skelegon tool on the 2 point poly chain.
Layer one should have your string of 2 point polys and your skelegons.
Layer 2 should have the chain.
In layout Parent Layer 2 to layer 1
Convert the skelegons to bones.
Animate the bones as usual which will animate the 2 point poly string.
Apply softfx to the poly string and immediately hit calculate
Metalink or Hardlink the chain to the the poly string.
This will allow the chain to bend but not stretch.
You can also apply IKBooster to the bones and animate them with dynamics. :)

jaketapia
12-13-2004, 09:53 AM
That totally worked. Thanks so much for the tip. This was my first project using LW's dynamics, so it was a big step up from basic animation. Why does it work that way? Does the 2 point chain work as a spline guide? Now I just need to figure out how to use IK Boosters Dynamics. Thanks again!

Jake

SplineGod
12-13-2004, 10:05 AM
Yes, exactly!. If you havent touched IKBooster yet theres a video tutorial over at Kurv that really covers it very well :)

ddoggett
04-24-2007, 06:07 PM
Thanks for posting the steps SplineGod. I must be a little slow because I followed them as well and didn't have as much luck as Jaketapia did.

I have a long stretch of barbed wire on layer 2. - no problem
I created a 2 poly chain with skelegons on layer 1. - no problem
In Layout I parented layer 2 to layer 1. - no problem
Converted Skelegons to bones - no problem
Apply softFX to the poly chain. - this is where is get confusing

When I apply softFX to the poly chain and hit calculate nothing happens. If I had clothFX instead and set Y = -9.8m and hit calculate you can see the polychain start to fall.

The problem is the whole thing falls. At one point I had one end stay put and the chain start to swing down but I locked up my machine and didn't remember how I got there. This is the effect I'm going for. I want one end to stay in play while the rest of the chain dangles. From there I want to be able to move or rotate the 'base' and have the chain react accordingly.

The barbed wire has 3 surfaces: Root_End, Tip_End and Wire.

Am I supposed to put HardLink on layer 1 or 2?

I'm so close I can smell it.

Dodgy
04-25-2007, 03:17 AM
Don't use softfx, it's more for fat like jiggly motion. Use ClothFX, and make a selection set in modeler of the points you want to stay pinned, and then select that selection set as the Fix value in clothFX. I would use a string of quad polys as this gives better opportunities for collision and twisting the chain.

ddoggett
04-25-2007, 01:27 PM
Yeah, I took another stab at it last night and figured out ClothFx is the way to go. I set a point selection for Fix and that helped secure one end. I've gotten much closer but have run into a weird issue. I posted a zip file of what I'm testing if anyone wants to take a look and see where I've gone wrong.

The zip file is at: www.dwendoggett.com/lw/barbed_wire_test.zip

I know right off the bat I should probably reduce the number of polys in the barbed wire layer. I think I went overboard in that area. Plus, reducing it would speed things up a bit.

I also probably have too many bones. I should probably cut it in half.

However, the problem now is that when I animate the poly chain things get weird. It's like its stripping out part of the barbed wire object layer to keep up with the ClothFx dynamics and the rest of the wire just stays put. Very odd.

This is the most advanced stuff I've tried with dynamics but I'm learning quite a bit during this process.

Any help or suggestions are most welcome.

SplineGod
04-25-2007, 04:49 PM
You can use softfx, clothfx, mdscan etc. They all do the same thing which is to bake motion onto each vertex. Metalink allows that object to deform another.
Make sure when using SoftFX you set both operators to NONE. Clothfx gives you the option of saving out the mdd file (displacement geometry data) and mdscan as well.

zapper1998
04-25-2007, 04:57 PM
Yeah, I took another stab at it last night and figured out ClothFx is the way to go. I set a point selection for Fix and that helped secure one end. I've gotten much closer but have run into a weird issue. I posted a zip file of what I'm testing if anyone wants to take a look and see where I've gone wrong.

I know right off the bat I should probably reduce the number of polys in the barbed wire layer. I think I went overboard in that area. Plus, reducing it would speed things up a bit.

I also probably have too many bones. I should probably cut it in half.

However, the problem now is that when I animate the poly chain things get weird. It's like its stripping out part of the barbed wire object layer to keep up with the ClothFx dynamics and the rest of the wire just stays put. Very odd.

This is the most advanced stuff I've tried with dynamics but I'm learning quite a bit during this process.

Any help or suggestions are most welcome.


I am doing the same thing for this PlayGround Equipment Co. and would really like to know the outcome of this, Thank you..
Michael

Dodgy
04-26-2007, 08:06 AM
Here's a demo scene. I've reduced the wire to subpatches too to speed things up.

ddoggett
04-26-2007, 05:30 PM
Thanks for posting the demo. I wasn't able to open it though as I'm still running LW v8.5.

ddoggett
04-26-2007, 11:57 PM
Okay, after some more play time I think I've finally got it.

I greatly reduced my poly count and changed it to subpatch. All good there.
Loaded into LW and did the following:

Parent Layer 2 (wire) to Layer 1 (poly chain)
Set ClothFX on Layer 1 with Y = -9.8m and used CottonThin
Set MetaLink on Layer 2 (HardLink didn't do the job - MetaLink was much better)
Set some keyframes and hit Calculate.

Viola!!! Worked like a charm! Thanks for everyone's help.

Now I've got two more questions.

1) How do I keep my barbed wire from getting stretched when it's flying around? I'm seeing distortion in it and I've tried playing with the Stretch limit but can't seem to quite get it keep it's shape.

2) Poly Chain - Is it better to have more polys or less? My assumption is that more is better in regards to accurate dynamics but impacts calc time. Thoughts??

Have I mentioned I'm having fun? I'm really enjoying learning this stuff and it's amazing to watch a simple wire go whipping around my screen.

Dodgy
04-27-2007, 03:18 AM
Make sure Stretch limit is 1% or so in the Advanced tab of Cloth fx to stop stretching.

Use as many polys as you need, and no more :)

ddoggett
04-28-2007, 08:42 PM
Here's another question. I'm trying the IK boost with a set of bones like SplineGod showed in a previous tutorial but I can't figure out how to link my barbed wire to the bone chain.

I have the wire on Layer 2 and the bones on Layer 1 and parented 2 -> 1. Then I added MetaLink to Layer 2 but nothing happens when I move the chain bones around.

Thoughts??

ddoggett
04-28-2007, 09:26 PM
Nevermind. I played around some more and figured it out. It's nice to have two options. I can use ClothFx from some of the scenes and then I can use IKboost for the scenes where I need to exercise more control over the wire(s).

Thank you to everyone for your help.

When I finish some scenes I'll post some quicktime movs.

SplineGod
04-28-2007, 09:43 PM
You can do both. Use IKboost on your proxy object. Once you animate it you can md scan it using any of the previously described methods and metalink the high rez barbwire to it.