Water in Blender, Wine in Yafray (fluid warning!)

Inspired by this thread, I started fiddling with the fluid simulator.

I wanted to pour wine from a bottle into a glass.
At first I encountered problems because the fluid would not get past the bottleneck (how symbolic :)), but then I spoke to N_T on IRC and he discovered it was a bug. A few days later that was resolved, and I could start baking properly.

Because (even at high resolutions) the fluids can’t really stay within thin-walled obstacles, I decided to work with thicker dummies for the simulation and the render with the actual objects >> which turned out to work fine. One problem with that was that when I decided it would be fun to let the fluid flow until the glass ran over, I stumbled upon this problem: that would not give the proper results (when the water runs over the edges). When I tried to bake at the maximum resolution of 200, it still leaked through the glass and the bottle. I’ll have to wait until N_T enables for even higher resolutions I guess!!!

Anyway, here’s the resulting animations. I can’t decide whether I like the Blender Internal render or the YafRay one. You can’t really compare because the BI render looked horrible when the wine (which is water now) had any color but white. Caustics on the yafray one are a bit too strong.

http://www.student.io.tudelft.nl/io1144677/blender/still-frame-12-yafray.pnghttp://www.student.io.tudelft.nl/io1144677/blender/still-frame-12.png

YafRay rendered simulation
Blender Internal rendered simulation

And the stats:
Simulation bake: 3 hours at fluid resolution 150, for 100 frames (4 secs, 0.40m size in the fluid tab)
Blender Internal rendertime: 4 1/2 hours at 50% PAL resolution (75 frames)
YafRay rendertime: 12 1/2 hours at 50% PAL resolution (100 frames)

Post-pro (motion blur) & compressed (Xvid) in VirtualDub 1.6.10

If anyone is interested in the .blend, tell me, I’ll post a link to it. JUST ASK!

Oddly, I think the Blender one looks more realistic than the yafray one.

I thought the animation looked pretty good but with some better lighting and glass material, it could look real.

If you wanted, you could reflect an environment in the glass and maybe fix the dribble that comes out the end of the bottle.

I know the render times are a pain though. But if you render overnight, it shouldn’t matter.

I agree that the water does look more realistic, but a colored fluid definately doesn’t look realistic at all like this in blender, because of the colored shadows (whereas you would rather expect a caustic spot)

I thought the animation looked pretty good but with some better lighting and glass material, it could look real.

I experimented a bit with an environment, but in the end I decided it does look better in a studio setup like this, with just a reflecting whitecard. An environment in this case doesn’t add a lot to the scene.

If you wanted, you could reflect an environment in the glass and maybe fix the dribble that comes out the end of the bottle.

I really do like the dribble! That’s what makes it more interesting to look at and a bit more realistic aswell IMHO.

thanks for your comments!

1 hour of baking for 1 second of movie? Calculating an hour would take half a year. I doubt anyone is THAT patient. :stuck_out_tongue:

That looks great!

I do agree that it takes WAY too long to bake that. Hopefully they’ll find a way to speed it up.

Neeat!

I’d definetly want to take a look at the blend file of that one, if I may.

*Fires up blender again - “Must … improve … now” *

Very nice! I had the same problem with the bottle too. I tought I was doing something wrong. I was too embarassed too ask if I was doin g something wrong, or weather it was a bug. Glad to see it is resolved :slight_smile:

same thing here. I wanted to make water splashing into a container, but it would hit the top like it hit an invisible plane. i hated that. i hope that was the same bug, because, if so, I’m back in business.

and i also think the blender render looks more realistic then the yaf.

still, very good work, inktvlek. you get two eProps.

Nice glass texture you got there man :slight_smile:

I’d like to see the .blend, if it isn’t too much trouble.:smiley: Thanks.

DwarvenFury

Very nice. Now all we need is interactions between two fluids :smiley: i.e. gasses and liquids to make bubbles.

Very nice! May I get a link to this “fluid simulator” you speak of?

The fuid simulator is part of the test builds. The specific ones can be found here (Windows) and here (OSX).

As long we are talking about bugs in the fluid simulator…
It seems that this fluid simulator is the light version of the real simulator. When I looked at all the on NT’s (www.ntoken.com) website, you can see some pretty complex simulations, like bubbles and such.

So it suprises me somewhat that Blender’s fluidsolver has bugs and that it hasn’t advanced features.

I’ve seen Zer03D demo for a particle based fluid simulation. It looks very nice in the sense that the fluid flows nicely obeying all the laws of physics in a complex container. This stuff is for Smoothed Hydrodynamics Particles (SHP).

About the advanced features (which I think is just bubbles): these are in his master thesis code, but to implement them into the blender fluid simulator library is a different thing. It is not just drag’n drop :slight_smile:

Zer03D = delt0r perhaps? His particle fluid system is far from finished. He’ll have something like floating bodies though, which is cool I think! From what I read, it works with java, so I’m not too sure about it’s speed!

But floating bodies, animated obstacles and predefined turbulance are definately on my want-list!

btw: .blend is coming. I found out I did not save the yafray settings, so you guys need to fiddle with this yourself!

I optimised my YafRay settings a bit (or rather re-did them because they were lost), decided for red wine instead of white wine and made the bottle green (like it should be for red wine). I rendered in 00:04:17.42 at full PAL resolution, so that’s quite acceptable for an animation even (the last yafray renders took about 6-7 for a frame and they were even at 50% (=1/4)).

http://www.student.io.tudelft.nl/io1144677/blender/rodewijngroenefles.png

and the .blend
this zip contains 2 .blend files, one with yafray settings, and one for blender’s internal renderer. You need to re-bake the simulation, the fluid files are way too big to share… If you want to bake just the first 20 frames for example, make sure you also lower the simulation time in the fluid tab proportionally(I need to talk N_T into making this update automatically according to animation range & fps)

HAA! That is awesome! :stuck_out_tongue:
Blender is supercool!

nice work man,
but in the recent yafray render, the wine and bottle should cast shadows with their respective colour in it. You may want to check the caustics.

all in all pretty nice work :smiley:

I dont know if this is ment to be happening or if it was a bug but, i love the way the fluid seems to stick to to glass of the bottle at the rim and a very small amount of wine goes backwards and missed the glass like it does in real life the fluid is acting with the proper surface tension.

I made another animation! I’m not quite pleased with it; the camera movement is too fast and I forgot to make the wine-label non-reflective. Also, somehow the wine looks too solid in most frames (if you look at them individually it’s not as bad). The caustics deserve a higher photonrate (which would have made the caustics a bit more defined), but I could not afford that for an animation :o)
I think this was my last try with this project, rendertimes are high but it was a fun thing!

This last animation was rendered in 9 1/2 hours (about 5:42/frame on average)
http://www.student.io.tudelft.nl/io1144677/blender/rodewijn-72.png

By the way, before you ask: Charissa is the name of my lovely girlfriend, and yes that is the yafray logo. I had a lot of fun making the label, even though you can’t see most of it :o)