FLIP Fluid Particles intersect collider and loose water vol.

   2462   4   1
User Avatar
Member
13 posts
Joined: Nov. 2019
Offline
I have a simple setup with a pre-animated bottle and I want to add liquid inside that bottle.
1)Particles go down and the initial water volume becomes flat... I tried to increase density but it's not working for me. How can I save the initial water volume? I need this bottle to be half-filled.
2) I don't understand why the bottle lets the particles pass by. But not all of them are passing by, some stay inside the bottle, but don't move according to the bottle's animation. Increasing substeps also didn't help. Any options on how to make it work properly?
Edited by vlad_akihabara - July 15, 2022 12:20:49

Attachments:
flip fluid issue.zip (1.6 MB)
01_2.jpg (82.8 KB)
02_2.jpg (82.9 KB)
03_2.jpg (85.3 KB)

User Avatar
Member
731 posts
Joined: Dec. 2006
Offline
In your case, you can make a proxy collision object that is super thick so that your sim has a better chance of "seeing" the collider. After the sim, you would then render the glass bottle you have here instead of the proxy collider.

This is a classic flip fluid issue. I would say the most important thing here is your substeps.... inside your solver, turn up the maximum substeps if you still have trouble. The problem (I think) is that the fluid velocity is super high and the particles never see your collision object because there are not enough substeps and your collision shape is very small.

Since you have a fast moving collider, you will need more global substeps too, and you have to make sure your collider is moving on subframes, (turn off integer frame playback and scrub the timeline to check). Houdini only resamples the collider at subframes if global substeps are above 1. (Remember that global substeps are a multiplier on min/max substeps inside the network, so adjust accordingly.)
Sean Lewkiw
CG Supervisor
Machine FX - Cinesite MTL
User Avatar
Member
2558 posts
Joined: June 2008
Offline
Mr. Catfish is correct that your source mesh is the weak link in your simulation. Notice that your bottle has a triangle fan pattern along the bottom. You can leverage this. I selected the center point of the fan and two outer edge points. After supplying them to a Rivet node at the /obj level, I was able to parent a line to the bottle. From this line, I skinned several circles to recreate the bottle in a quad-only fashion. This allows for better sourcing and addresses the main problem, which is creating a thicker outer collision wall. By adjusting the line length you can set the fluid level in the bottle, too.
For flip collision objects containing liquid, having a thicker outer wall means you can run the simulation at a lower resolution and produce results more quickly on low-end hardware. This is because you don't have to crank the collision resolution as high, by lowering the particle separation.
Another problem with this scene is the ridiculous speed at which it takes place. No bartender can pour multiple shots that quickly without spilling fluid.(Perhaps cartoon dude Perfect-Pour Pete?) To get around this, I set the FPS to 120, not 30. This makes the simulation four times longer, but you don't have to deal with sudden velocity changes. It's kind of like adding substeps, but by running the simulation slower, you can use the default substeps to develop the effect quicker.
To top it off, I added a little viscosity to tame the pour.
Edited by Enivob - July 16, 2022 10:44:30

Attachments:
cartoon_pour.gif (396.9 KB)
ap_fluid_bottle_pour_sim_01.hiplc (2.6 MB)

Using Houdini Indie 20.0
Windows 11 64GB Ryzen 16 core.
nVidia 3050RTX 8BG RAM.
User Avatar
Member
13 posts
Joined: Nov. 2019
Offline
mrCatfish
In your case, you can make a proxy collision object that is super thick so that your sim has a better chance of "seeing" the collider. After the sim, you would then render the glass bottle you have here instead of the proxy collider.

This is a classic flip fluid issue. I would say the most important thing here is your substeps.... inside your solver, turn up the maximum substeps if you still have trouble. The problem (I think) is that the fluid velocity is super high and the particles never see your collision object because there are not enough substeps and your collision shape is very small.

Since you have a fast moving collider, you will need more global substeps too, and you have to make sure your collider is moving on subframes, (turn off integer frame playback and scrub the timeline to check). Houdini only resamples the collider at subframes if global substeps are above 1. (Remember that global substeps are a multiplier on min/max substeps inside the network, so adjust accordingly.)
Now I understand why I have troubles with intersecting. Thank you for the reply!
User Avatar
Member
13 posts
Joined: Nov. 2019
Offline
Enivob
Mr. Catfish is correct that your source mesh is the weak link in your simulation. Notice that your bottle has a triangle fan pattern along the bottom. You can leverage this. I selected the center point of the fan and two outer edge points. After supplying them to a Rivet node at the /obj level, I was able to parent a line to the bottle. From this line, I skinned several circles to recreate the bottle in a quad-only fashion. This allows for better sourcing and addresses the main problem, which is creating a thicker outer collision wall. By adjusting the line length you can set the fluid level in the bottle, too.
For flip collision objects containing liquid, having a thicker outer wall means you can run the simulation at a lower resolution and produce results more quickly on low-end hardware. This is because you don't have to crank the collision resolution as high, by lowering the particle separation.
Another problem with this scene is the ridiculous speed at which it takes place. No bartender can pour multiple shots that quickly without spilling fluid.(Perhaps cartoon dude Perfect-Pour Pete?) To get around this, I set the FPS to 120, not 30. This makes the simulation four times longer, but you don't have to deal with sudden velocity changes. It's kind of like adding substeps, but by running the simulation slower, you can use the default substeps to develop the effect quicker.
To top it off, I added a little viscosity to tame the pour.
You're absolutely amazing! Thank you a lot for your help. I learned many interesting tips from your example file.
  • Quick Links