PDA

View Full Version : Foam and Suds


ntmonkey
12-08-2009, 01:25 AM
Hello,

Working on an effect that needs some foam and suds. Been giving nParticles a chance, but finding the meshing is REALLY slow and not flexible compared to Realflow. So now, I'm looking for CG examples of really nice looking foam and suds. More like shampoo suds and not large-scale ocean foam.

If anyone has tried something like this, I'd love to hear about it.

Thanks in advance,

-Lu

ntmonkey
12-08-2009, 07:10 PM
Wow. Friend of mine sent this awesome spot to me. Looks like some parts of it could be CG (wide shots). Good reference for foam. Don't need it to be this crazy but I love the look. Still stuck. :(

http://vimeo.com/974656

-Lu

Aikiman
12-08-2009, 08:32 PM
Looking at your vimeo sample I reckon maya fluids could handle something like that. With the right texturing and opacity ramp you could do the bulk just by animating the texture origin and/or time without anything being dynamic (or not), it all depends on your skillset with fluids and the type of shot you are after of course.

For the swirly animated effects probably still achievable in fluids but nParticles would probably be easier to use, just try and match the fluid shader and combine the 2 in post.

ntmonkey
12-09-2009, 06:48 AM
Thanks Aikiman for your reply!

Finding that a lot of this is gonna come down to getting a shader that will look like foam when applied to a mesh. Be it realflow or Maya, think in the end, it'll be meshes flying around.

Going to try to put up a few tests if they're any good. Thanks again for your suggestions. I'll probably take some nParticles for some hero bubble elements.

Cheers,

-Lu

ntmonkey
12-11-2009, 10:00 AM
update:

Poor presentation, sorry. First go at foam shader. Just a fast SSS. Need to get some sorta sparkly mix in there. Some have said multilayered shader or even seperate sparkly pass and bosch in post. Should try to get the sparkly bit, some hero bubbles, and a sim from realflow. Maybe when they all mix together it'll read as foam.

All suggestions welcomed. Shaders are not my strong suit. (Maya MR)

-Lu

http://www.mlu3d.com/foamTest2.jpg

Bonedaddy
12-11-2009, 04:39 PM
We have some foam in the movie I'm on right now. The guy has it broken out in a couple passes:

- Base mesh that provides the main movement (the shots have the foam, largely, in one big lump)
- nParticles on top of it that are goaled to the surface, but can move around a bit, and are affected by fields.

The base mesh is rendered with a SSS-type shader, nParticles rendered individually (i.e. as spheres, not meshed) with a bubble shader that gives them a sort of specular chromatic abberation across the surface (think oil "rainbows").

It's produced pretty good results, at least so far, but it's been for a large mass. When he's had to do splashes, he's just used the nParticle setup and it's seemed to work okay so far. What are the constraints of the shot?

ntmonkey
12-11-2009, 05:10 PM
Hey Jason!

How's it going?!

Looking over the plates now and I'm feeling much better about it. Part of me still wish that I could have some sort of 3D voronoi volume shader with the chromatic abberation effect.

Thanks for your suggestion. It's a solid approach. Kinda heading that way so it's reassuring.

-Lu

Bonedaddy
12-11-2009, 08:33 PM
Hey Lu. How's tricks? I keep seeing you pop up on Wave.

I don't know how much MR is really capable of without significant hackery, but I'd try and shoot for a Perlin Noise-based shader, making the XYZ based locally to each particle, with an initial translation offset defined by the position of the particle (plus some random seed distance based on id). Blend that with a fresnel falloff, to make it more prominent depending on the facing ratio, and you'll be in the ballpark. Voronoi shader would be cool, but maybe a little overkill. I think one of the standard noise algorithms would work ok.

The only caveat I have is that SPH-enabled nParticles and goals do NOT play well, a lot of the time. You may have to resort to elaborate trickery to mimic goals.

Dunno how applicable these suggestions are to your situation. I've been stuck in proprietary pipelines, Houdini, and the occasional bit of Renderman for so long, it's kind of hard to remember Maya specifics sometimes.

Aikiman
12-14-2009, 10:37 PM
Not sure why Im having probs uploading a file to CG, I did this last week just FYI using fluids. Didnt really think about how you'd match the shader or even if you can plug in a facing ratio node.
I like the asymmetry of the result though, probably not much use for you now.

http://img96.imageshack.us/img96/9673/foam.jpg

ntmonkey
12-15-2009, 11:29 PM
Cool example there Aikiman. It's always good to see the approach and the result. Got sidetracked doing other stuff, but will come back with some examples. It's kinda gotten personal now. :p

kaworuonline
01-20-2010, 06:28 PM
Not sure why Im having probs uploading a file to CG, I did this last week just FYI using fluids. Didnt really think about how you'd match the shader or even if you can plug in a facing ratio node.
I like the asymmetry of the result though, probably not much use for you now.

http://img96.imageshack.us/img96/9673/foam.jpg

The look of foam u made is great, and I can't believe that it is maya fluid purely. Would u mind share the setting of fluidshape, or even the whole file?
Thank you very much
(If u can't find the way upload to forum, plz send it to my email kindly)

Aikiman
01-22-2010, 08:37 PM
Hi there,

unfortunately I didnt keep the file but to achieve that look, its all mainly in the texturing (obviously). I think I used billow with invert texture on and all the grids are static, you are just working with the density and opacity grids.

One method I like doing to visualise what texturing does is to use Mayas pond and go crazy with all the texturing options, the spring mesh updates instantly so you dont have to wait until you render something before you can see your result.

Have fun.

CGTalk Moderation
01-22-2010, 08:37 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.