breaking a dam with realflow

Discussions about rigidbody simulation in Realflow 4
benlink
Posts: 34
Joined: Tue Apr 10, 2007 5:45 pm

breaking a dam with realflow

Postby benlink » Sat Apr 28, 2007 8:57 pm

so ....is this the tip to make the particles go out of the mesh that was filled or not?:)


shaun_michael
Posts: 4766
Joined: Sun Sep 10, 2006 8:04 am

breaking a dam with realflow

Postby shaun_michael » Sat Apr 28, 2007 9:26 pm

No, I was imagining you having modelled the lake at the rear of the dam and having filled an object with particles to then allow it empty into the valley and rush at the dam, or simply use a volume setting on your emitter instead of a speed setting. Simply filling an object with particles and then deactivating it will cause the particles to fall straight out of the bottom of it - not what you're after. If you're using a fill object to drop particles from onto a terrain of some sort, then this is a useful techinque not only to generate some velocity in your particles, but also to sculpt it in some fashion.

The very basics of this are relatively simple. Build a dam in hte middle of a model of a valley, fill one side with particles, break the dam. How you go about this is up to you of course, but it's fairly straight forward but I would strongly suggest watching the poly count, and thinking very carefully about what exactly needs to happen.

Can you answer me three things:-

1) Does the entire dam get demolished or does it just get partly demolished [this will help you in setting up the dynamics of the dam]]
2) How does the water approach the dam, at a rush, or is it there, as a lake all along? [This will help you in setting the scene and also may allow for some scene optimisation and lateral thinking during set-up]
3) What is the motivation for the dam breaking? Does it crack and then give way, is there something that happens behind the dam and is it above or below the waterline behind the dam. [This ensures that the end result is believable]

Generally you find a dam with a big lake behind it, and a controlled amount of fluid being allowed through sleuce gates, either generating electricity in the process, or there as flood protection or something.

You need to set up your scene and finalised exactly what it is you want to do both before and after the dam breaks, how the dam breaks, why and to what extent. Also, how is the water introduced and where from.

Pop all the answers in a post and then we'll both know exactly where to go from there :)

Shaun

benlink
Posts: 34
Joined: Tue Apr 10, 2007 5:45 pm

breaking a dam with realflow

Postby benlink » Sat Apr 28, 2007 10:19 pm

1) well....I would say that 85 per cent of the dam is destroyed
2)...in fact the water is supposed to be there, like a lake...
3) in fact, the dam it self is being filled with water( but Ihaven't the time to make a mesh filled with water, I will only concentrate on the water behind the dam) and then it cracks and give away....
so my dam is precut......a t the begiining I tried to break it with simple emitters....but the fact is ...its seems violent but I'm searching for something else...on the other hand , having a whole lake behind may be longer to simulate...

shaun_michael
Posts: 4766
Joined: Sun Sep 10, 2006 8:04 am

breaking a dam with realflow

Postby shaun_michael » Sun Apr 29, 2007 8:37 am

OK, so only a small portion of the dam breaks, a lake is behind the dam etc.

So build your terrain, and dam, and only build the separate blocks of the dam where you want the dam to break - the rest can be one single object that has no dynamic motion at all.

Also, construct an object, without depth, that exactly matches your lake shape that will sit behind your dam - make if fairly high resolution. This will be the lake using a custom realwave object. If your dam is perfectly straight, you can just use a standard RW object for this and set it up with static points where it overlaps your terrain geometry.

You can now simulate your wave travelling along the lake, but I wouldn't do it with am object unless the scene calls for it, I'd set it up with a control point wave and animate a few points at the back end of the lake to give me the travelling wave. Once you've simmed this, you can put it into cached mode so that it doesn't get simmed again.

For your water I would set up an emitter slightly behind the section of the dam that is due to break, underneath the realwave surface (where it wont be seen), placing a (or some) K_volume object(s) underneath it so that any particles that stray are killed off. You should be able to set the speed quite high. Now run a few tests tweaking the weight and friction of the dam blocks so that they move with the force you're after when the water hits them.

Of course this assumes that you want the dam to break below the waterline.

You should also settle the single dam blocks into position first by locking the sim and running a few frames so that everything is in place before doing any RW or particles sims.

Hope that helps,

Shaun

benlink
Posts: 34
Joined: Tue Apr 10, 2007 5:45 pm

breaking a dam with realflow

Postby benlink » Sun Apr 29, 2007 8:46 am

thanks a lot shaun.
but I don't need RW since we do not see the lake behind the dam....the cam is always at the bottom of the dam...and the wave is for after...lol
but I think I find a solution.. I've filled a mesh with particles...Once it was filled, I've deleted themesh but not the fill object emitter( I used the initial state thing).... and then this block of water is just behind the dam and I suppose it will break it as there is a ramp in order to guide the water....
the only thing is...do I have to increase the ext and int pressure so that the water "bounces" more and is more agitated?

shaun_michael
Posts: 4766
Joined: Sun Sep 10, 2006 8:04 am

breaking a dam with realflow

Postby shaun_michael » Sun Apr 29, 2007 2:49 pm

OK. Well you didnt necessarily have to fill an object at all, you could have just use something like a square emitter behind the dam and set it to be a volume emitter instead.

As for more agitated water:-

If your scale is 1.0, I'd go for something like this to start with...

Res no more than 10 initially
Density 2000
Int pressure 0.01
External Pressure 1.0
Viscosity 0.8 to 1.0
and surface tension 10

Then I'd tweak from there. Make sure you've set your compression parameter (File>Prefs>simulation) to about 10,000.

See how that goes.

Sometimes for testing you can go for a low res test, or you can drop your max substeps down to something like 50 so the test goes faster, but it will be at the expense of accuracy.

Have fun.

Shaun

benlink
Posts: 34
Joined: Tue Apr 10, 2007 5:45 pm

breaking a dam with realflow

Postby benlink » Sun Apr 29, 2007 7:55 pm

my scale is 0.01.
so what settings would change? I know the resolution does....but I mean..will the compression setting be the same or does it really change according to the scale?and the surface tension?

shaun_michael
Posts: 4766
Joined: Sun Sep 10, 2006 8:04 am

breaking a dam with realflow

Postby shaun_michael » Sun Apr 29, 2007 8:15 pm

All values change for the particles, but I'm not sure about the compression parameter. You could either run a few low res tests on test objects, or, change your scale to 1.0 in RF and scale it back when you get back to your 3D app.

Shaun

benlink
Posts: 34
Joined: Tue Apr 10, 2007 5:45 pm

breaking a dam with realflow

Postby benlink » Sun Apr 29, 2007 8:24 pm

a scale of 1.0 is too big in RF for me...as I work with 3dsmax....thanks a lot...
oh...and I've got a final question:
when hitting the dam with emitters and not a volume behind it...I actually like the way the dam is hit at some parts as it seems like there is a lot of pressure....
so is it possible to have the same "agressivity" from a volume filled with water(perhaps thanks to daemons or a int pressure quite high?)? or then do I have to mix the two and make one mesh out of them?

and oh yeah..the beer script works fine for foam.....but just one thing....if I have more than one emitter in the scene.....how does it work? I have to load this script in the event layout several times right?

shaun_michael
Posts: 4766
Joined: Sun Sep 10, 2006 8:04 am

breaking a dam with realflow

Postby shaun_michael » Mon Apr 30, 2007 7:31 am

a scale of 1.0 is too big in RF for me...as I work with 3dsmax

It doesn't matter what scale you use in RF when it comes to relating to your 3D application. What you're after is the way scale affects your particle movement. I'll leave that up to you.

when hitting the dam with emitters and not a volume behind it...I actually like the way the dam is hit at some parts as it seems like there is a lot of pressure....
so is it possible to have the same "agressivity" from a volume filled with water

Only if the particles have sufficient momentum. You could try setting up a Dspline daemon to guide the particles in your voume and accelerate them, but I'm not sure how affective that would be. There are a number of daemons that exert forces on particles, so perhaps you could investigate how they affect your volume and whether they give you the right sort of look.

if I have more than one emitter in the scene.....how does it work? I have to load this script in the event layout several times right?

I dont think you can have more than one events script running at one time. I'm not a scripting expert, so perhaps Thomas or others can answer this one, but my assumption would be that you'd need to write you other liquid emitters into the script.

Shaun


Return to “RF4: Rigidbody simulation”

Who is online

Users browsing this forum: No registered users and 1 guest