Gel shader or liquid simulation?

So i’m working one something and fiddling with ways to get some realistic gel within a solid glas cyclinder.
I did some test’s with just simple shaders but it’s not the way i want it to be yet. The left example shows just 2 Principled shaders mixed together, so the same object act as glas and the fluid. The middle one has a separate solid glas cyclinder that should be filled. I already tried to put the simplified gel inside the glas (intersecting the glas for correct rendering) but the gel itself looses alot of color, as well as the structure is very hard to guess. Also with just a shader on a single material, it’s hard to separate the glas effect from the fluid so it looks half filled as well smearing some parts.

Stuff is WIP, so ignore fubar here and there.

So i wonder if a liquid simulation is the best way to fill the cylinder (good side effect: free bubbles) but im afraid the glas and it’s refractions will eat a lot of it’s shape. So what are the ways you would go for it?

did you try with a glass shader and some texture as a roughness map may be?

happy cl

I think that what makes gel in glass look like gel is flock of tiny bubbles and some color tint - greenish or blueish. And maybe surface is little waved and borders of surface of gel is little lifted along glass…

did you try with a glass shader and some texture as a roughness map may be?

As described, the left is a single mesh with a combined glas material, so yes.

In the image, i tweaked the material and lighting a bit. I also added ~20 bubbles to see their effect. The difficulty i have is to manage the shape for the fluid if it’s in the same material on a single mesh. If you separate the fluid and glas to their own materials as well as meshes, caustics gonna eat a lot of color and most of the fluid shape, even without volume absorbion.

There is a emissive ring inside to catch some refraction highlights and make the material a bit independent of the overal lighting. The shape i painted in is what i want the glibberish to look, while white should be the pure glas hull.

You are right, bubbles make a lot of it’a appearance, as well as it can preserve the abilitys of water in motion. So it’s somewhat a time freeze of water falling into a glas.

I have never spend time on particles so i was about to avoid them :slight_smile:

interesting mat
can you share file or show all nodes setup
if anyone else need something like that
can be re use!

happy bl

1 Like

Credits to @RemingtonGraphics for it’s base setup too. Noise node can be replaced by any texture that produce glibberish output. IOR’s and displacements have heavy influence, so handle them with care. You don’t need to displace if you already baked a fluid sim or have a sculpt for the shape. Absorbtion is opt-in.

Still not fine with it, looks like a ugly aquarium x_x


I don’t find it too bad ! Have you got some reference images of what you’re trying to acheive ?

Yes, tho i have 2 real examples (hair gel and dryed dishing fluid) at my directly at my hands to look at. Basically everything that is very jelly and sticky may fit. Dryed Dishing fluid for example, if you shake it in a bottle, it should get you some nice bubbles and a honey like effect.

The one in the middle is a very close example at what it should become. When you want to place decals on the glas, it gets more clear why it should have a glas layer between.

how about these ?


happy bl

why not making a bubble object and fill it with the particle system(with your object) and some random size into the cylinder?and use a glass shader for the bubbles,then add a volume absorption shader like you have at your shader.maybe a little volume scatter can help too,just try out.

You’re describing physical properties rather than optical ones. On the middle example, if you have it around, how does it look with no bubbles and you have a checkered pattern behind it or filming it with a moving lit lighter behind it? Here it only look like volume absorption and not what the ior does.

To add a fixed absorption you can setup a custom glass using fresnel to mix colored refraction with white glossy. Dealing with interfaces is something I fail at every time. So I doubt I can help much, just thought I’d throw it out there.

here a quick render with particles

1 Like

how about that one here
it is a combination of 3D model and refraction I think

wow nice render! can you share the node?

i cant remember the file name or if i have even saved this.this was a glass shader or principled shader with transmission(its almost the same) and particlesystem with little icospheres iirc.with the same glass material.maybe the spheres with flipped normals to the inside for internal reflections.

was it your model or CG master ?

I can find the file and upload it if not too big

happy bl

the gel shader… thanks

the gel render was a simple cylinder with subdiv and loopcuts at the ends

I found the render with a dragon
but it is too big to upload = 128 MB

are you talking about that one or another model ?

I got a few other liquid nodes setup

happy bl

have this gell nodes

is it that one ?

happy bl