PDA

View Full Version : Animated flexible hoses.



Otterman
02-20-2015, 07:37 AM
Ok I thought I'd through this out to the community. It has been my achilles heel for sometime as my current way of doing it is very haphazard and I wondering with the evolution of Lightwave in it's current form there might be a better way of doing it.

Essentially I have some hydraulic rubber hoses.....(a lot of them) that I need to rig so they play nicely when the arm is animated (see attached pic)
I use the old null, bones, IK and goal trick. Based upon *Splinegod's Dog Leash tutorial. It works but I find the end of the IK goals slip to heck.

Is there any easier and more effective way of doing it these days? What technique and/or plugin should I explore. Any help appreciated



*Sure miss him being around here. RIP

Chrusion
02-20-2015, 08:36 AM
Hmmm... I work in the same industrial mechanical realm as you and have avoided hydraulic hoses for this very reason. But, I wonder if using good ol' cloth FX would work? As in, making both ends fixed and setting the other params to keep the hose stiff and rigid, yet flexible (high spring strength, zero or 0.0001 stretch, etc.). Well, that wouldn't work (both ends set to fixed), because one end needs to be parented to its base moving member and if the other end is fixed, too, then it will move the same amount as the other end. So, I wonder if adding a bone to the opposite fixed end and parenting it to the sibling moving object would work?

But, then there's bone dynamics in 2015, so maybe all it takes is a string of bones in the hose with starting bone parented to the base member and the ending bone parented to the sibling member and then setting up whatever it takes to make the rest dynamic, like a chain without gravity. Might be several other options.

Otterman
02-20-2015, 08:48 AM
Hi Dean

Cloth you say !?! never worked with it so at least it's something worth exploring. Thanks for chipping in.

I just came across this...

http://www.worley.com/E/Products/taft/man_hoser.html

I have emailed them to see if this a viable solution. Also a trial version to evaluate before purchase. I need a simple and robust solution.....and erm...flexible hehe.

RebelHill
02-20-2015, 09:16 AM
Spline control can work... though bones and IK is perfectly viable, just need to set it up right to make the IK behave properly. There's a walkthrough on doing a digger just like this in my rigging tutorial series.

Surrealist.
02-20-2015, 10:06 AM
Hmmm... I work in the same industrial mechanical realm as you and have avoided hydraulic hoses for this very reason. But, I wonder if using good ol' cloth FX would work? As in, making both ends fixed and setting the other params to keep the hose stiff and rigid, yet flexible (high spring strength, zero or 0.0001 stretch, etc.). Well, that wouldn't work (both ends set to fixed), because one end needs to be parented to its base moving member and if the other end is fixed, too, then it will move the same amount as the other end. So, I wonder if adding a bone to the opposite fixed end and parenting it to the sibling moving object would work?

But, then there's bone dynamics in 2015, so maybe all it takes is a string of bones in the hose with starting bone parented to the base member and the ending bone parented to the sibling member and then setting up whatever it takes to make the rest dynamic, like a chain without gravity. Might be several other options.

Yes you can use Bones to fix at as many points as you want. For this to work it requires you to rig the tubes with the bones. So that there is a weight map moving the tube. It does not have to be deforming it properly. I mean the whole tube that is. It just has to be moving the points through space with the animation. So you'd have a map and value for each section that needs to be fixed. You then create another vertex map for the parts you want fixed. Only those vertexes. Since they are also being animated by the bones and moving through space the cloth sim will give those points over to the deforming mesh. Hope that makes sense.

Not saying it is the best way to set this all up as far as a rig solution for the tubes. I just wanted to clarify that point.

Chrusion
02-20-2015, 10:52 AM
I don't think Taft Hoser will work. I've used it for straight cables laying on the ground being "picked up" and moved to their anchors. Hoser has "built in" gravity, so the cables drooped as desired when the two end-point nulls were closer together than the length of the cable, so this is the reason I don't think it will work with hoses that aren't modeled as straight (curved/arched).

The Dommo
02-20-2015, 11:00 AM
Can you use bullet, like this tutorial?

https://www.lightwave3d.com/learn/article/bullet-dynamics-introducing-bone-dynamics-in-lightwave-2015/

motivalex
02-21-2015, 04:10 AM
Spline control may be a good bet in 11.6+. Just done a animation with safety flexible cables attached to harneses, needing to follow the movement of the worker, while the other end remains attached to a wall hoop. So similar in principle. You can use IK and set the bones to 'fit to spline' apart for possibly the first and last bone to stop stretching at the begnning and end. There are a couple tuts on lightwave3d.com. The siggraph presentation got me started on it and Rebelhills tuts are worth a look at too.

Slartibartfast
02-22-2015, 10:04 AM
Hi there!

I tried it out and came up with this. Short description on how it works:

1. make a two-point-polychain and the "hose" in another layer
2. make a weightmap. The outermost points (in the polychain) should be set at 100 %, and the rest 0%
3. bring it over to layout, and add two control nulls. These nulls should be parented to the excavator parts or whatever moving parts you want.
4. make the endpoints in the polychain follow the nulls (you can see how I did that if you enter properties/deform tab/node)
5. apply clothfx on the polychain.
6. adjust parameters.
7. Hit calculate
8. go back to 6 twenty times
9. apply metalink to the hose. make sure the polychain is the parent of the hose!
Enjoy! Hope it works for you

cheers / Slartibartfast

Scene: 127145

zapper1998
02-22-2015, 11:18 AM
Oh ya I did this on my Caterpillar Crawler Unit awhile ago and Hoser works Awesome for the hoses..

Greenlaw
02-22-2015, 06:25 PM
Another option: DP Spline Deformer should work for this. With this tool can use nulls for spline handles--no need for bones. The nulls, of course, can be parented to anything.

Easy peasey instructions:


First add the Spline Deformer node to the hose mesh.
Next create the nulls you want to use as 'knots' for the deformer and add them to the tool.
Connect the tool's Delta to the Input.
Enable Nodes for the hose mesh.
Next, position/rotate the nulls to shape the hose.
Finally, parent the nulls to the appropriate parts or bones of the machine.


G.

Otterman
02-22-2015, 08:14 PM
Wow thanks guys a lot for me to try and get my head around. Heres me thinking the forums were slowing down and not being as helpful as they once were but heck you all proved me wrong.

Still unsure which would be the best approach. I have the hoses modelled in a single state which look absolutely fine in that fixed pose, however repositioning the arm I need the hoses to not only conform to beginning and end of the hoses but also bend as they should so I think dynamics might be a little too haphazard especially as there are several to account for. It's a nifty solution but a little too unpredictable.

I tend to model a nice clean length of hose and use bones to pre-bend into shape which seems to work well. Just my IK and goal set up seems to let it down.

So, I either brush up on my bones and IK method.
Look into Spline control, DP Spline Deformer.
or potentially invest in Hoser.

Ok time to get busy.

Cheers fellas

Otterman
02-22-2015, 10:51 PM
Another option: DP Spline Deformer should work for this. With this tool can use nulls for spline handles--no need for bones. The nulls, of course, can be parented to anything.

Easy peasey instructions:


First add the Spline Deformer node to the hose mesh.
Next create the nulls you want to use as 'knots' for the deformer and add them to the tool.
Connect the tool's Delta to the Input.
Enable Nodes for the hose mesh.
Next, position/rotate the nulls to shape the hose.
Finally, parent the nulls to the appropriate parts or bones of the machine.


G.

wow...that is easy. DP..rocks! Now time to try it will a full rig and multiple hoses. Thanks GL.

watch this space

Greenlaw
02-23-2015, 03:37 AM
Hope it works out for you.

BTW, to add the nulls, you select each one from the list in the tool's interface and then click Add Selected. (Something like that...I don't have Lightwave in front of me at the moment.)

If you have questions, just ask here. For some tasks (like this one,) I like using DP Spline better because it's a simpler setup and the handles on the nulls allow you to adjust the curve size so you might have more precise control over the hose/spline shape.

Spline Control certainly has its own strengths and advantages though and, IMO, it's good to know how to use both and know when to use the right one.

G.

jwiede
02-23-2015, 12:19 PM
Oh ya I did this on my Caterpillar Crawler Unit awhile ago and Hoser works Awesome for the hoses..

Yeah, Worley's Hoser plugin (part of Taft collection) basically figures out the hose bending and drooping for you, you just model the hose "straight" and then move the nulls into the proper positioning and bingo. It's pretty quick as well, likely significantly more so than most of the "simulation" approaches described. Plus you'd get the rest of Taft plugins which are also quite useful.

jeric_synergy
08-18-2015, 10:34 PM
Spline control can work... though bones and IK is perfectly viable, just need to set it up right to make the IK behave properly. There's a walkthrough on doing a digger just like this in my rigging tutorial series.
When I googled "lightwave rigging hoses" I thought I'd get MUCH older hits than from this current year...

As a rigging clutz, I was thinking Spline Control was overkill, but I guess I'll know more in a couple hours.
https://www.youtube.com/watch?v=gCVneRb141I&index=16&list=PLTds3QePYrWEWipwKkLmyNT4Tf_JTigM2