rlguy / Blender-FLIP-Fluids

The FLIP Fluids addon is a tool that helps you set up, run, and render high quality liquid fluid effects all within Blender, the free and open source 3D creation suite.
https://www.blendermarket.com/products/flipfluids
GNU General Public License v3.0
1.7k stars 190 forks source link

Banding artifacts against gradual sloping obstacles #1

Open rlguy opened 6 years ago

rlguy commented 6 years ago

A banding effect can be seen in the fluid particles when a thin layer of fluid is sliding down a gradual sloping obstacle.

artifact_grouping

Example .blend file: https://www.dropbox.com/s/a9om9oimpbiii0a/gradual_slope_banding_artifacts.blend?dl=0

Note: this issue is about simulation banding artifacts rather than mesh banding artifacts. Simulation banding artifacts cause particles to group and align to the grid. A fix for mesh banding artifacts can be found here: https://github.com/rlguy/Blender-FLIP-Fluids/wiki/Scene-Troubleshooting#mesh-banding-artifacts-against-curved-obstacles

EverSimo commented 6 years ago

I've noticed this behavior too.

Beach Render (unfinished)

Any hope to get a solution for this artifacts?

rlguy commented 6 years ago

Yes, I hope to get this fixed, but have not yet had time to test different solutions to this problem.

By the way, I am not able to view your video link:

Access to r4---sn-q4flrner.googlevideo.com was denied
You don't have authorisation to view this page.
HTTP ERROR 403
EverSimo commented 6 years ago

Please, try again... sorry...

Beach Render (unfinished)

niklassjogren commented 6 years ago

Could this be the same error, I get some strange lines in the fluid in a whirling motion, or is it me? https://gfycat.com/DirtyFinishedAphid 0038 /Niklas

rlguy commented 6 years ago

Hey niklassjogren,

This looks like it is actually a meshing issue rather than a simulation banding issue.

The mesh generator uses a grid to convert particles to a triangle mesh. When thin layers of fluid are against an obstacle, the particles may not show up well on the meshing grid. Some fixes for this are to:

  1. Increase surface subdivision level - This will create a finer mesh grid and generate a higher quality fluid mesh. This will also take more time to compute. This setting is located in the FLIP Fluid Surface settings.
  2. Increase particle scale - This will increase particle size when meshing. The particles will show up better on the meshing grid. This does not take much more time to compute, but your fluid surface may end up looking 'blobby'. Try setting the scale to something like 1.50. This setting is also located in the FLIP Fluid Surface settings.
grantwilk commented 6 years ago

image Seeing similar issues in my wave simulations. Hoping this issue hasn't been forgotten :)

rlguy commented 6 years ago

This issue haunts me and I can assure you it has not been forgotten! I spent a few hours earlier this week to try a few things, but did not find a solution. I've come to the conclusion that I should build some debugging tools to better visualise/understand what could be causing this issue whether it be a bug or flaw in the simulation method. I've actually planned to devote the entire week of April 23rd - 27th to work on this if needed!

enzyme69 commented 6 years ago

I am getting same issue with what I am doing (obstacle with lots of curvey surface). Banding happens, when radius increased, it becomes too blobbies...

rlguy commented 6 years ago

Hey @enzyme69, if increasing particle radius is making the fluid too blobby, I would suggest trying to increase the subdivision level to 1. This will improve the detail of the surface and can help fill in the banding gaps.

PavelBlend commented 5 years ago

Another way to get rid of these artifacts is to disable the "Mesh Around Obstacles" checkbox. But in the last experimental build there is no this parameter. I often turned off this checkbox.

rlguy commented 5 years ago

Meshing in the later versions have changed and the Mesh Around Obstacles option was removed due to being out of date and no longer compatible. The new default setting for how fluid is mesh around obstacles (Mesh Inside Obstacle) works similar to the old Mesh Around Obstacles and can help reduce meshing artifacts.

Note: this issue is about simulation banding artifacts rather than mesh banding artifacts. The simulation banding artifacts cause particles to group and align to the grid:

artifact_grouping

Many of the comments in this thread are related to mesh banding artifacts (of which here is a fix). I'll add a note about this to the top post and hide some comments to make this issue more clear.

zx-82 commented 3 years ago

Any updates on this ? I am developping my own fluid simulator and am confronted with the same issue. I suspect that it is related to the "small cell" problem (common to all cut cell based liquid solvers) because along a gradual slope there will be cells (fractions) that only contain an arbitrary tiny amount of fluid. In engineering CFD codes this problem is addressed by merging "tiny cells" with neighboring cells. While solvers used in computer graphics seem to rely on Bridson's simple "clamping trick". But this will also leave some residual "stair casing", I'm afraid.

rlguy commented 3 years ago

There is no update on this issue and it has been at least two years since I have had a chance to look further into the problem. The "small cell" problem sounds like a good lead for something to look into for this issue. Thank you for the tip, but I am sorry to say that I do not have any advice at the moment.

Good luck with your fluid simulator development!

zx-82 commented 3 years ago

Hi, 

 

I am sorry to say that I do not have any advice at the moment.

 

Thanks for your reply which is actually helpful because your (and mine so far) failure to find a simple way to resolve it, indicates that this banding is indeed related to math method/algorithm. So at least no need to wasting time chasing an imaginary bug in the software.

 

Best Regards,

  Bernhard

   

Gesendet: Montag, 01. November 2021 um 18:46 Uhr Von: "Ryan Guy" @.> An: "rlguy/Blender-FLIP-Fluids" @.> Cc: "zx-82" @.>, "Comment" @.> Betreff: Re: [rlguy/Blender-FLIP-Fluids] Banding artifacts against gradual sloping obstacles (#1)

 

There is no update on this issue and it has been at least two years since I have had a chance to look further into the problem. The "small cell" problem sounds like a good lead for something to look into for this issue. Thank you for the tip, but I am sorry to say that I do not have any advice at the moment.

Good luck with your fluid simulator development!

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

PavelBlend commented 1 year ago

@rlguy I turned on the enable obstacle debugging option and saw that the stripes are located near the small polygons: 0 1 2 3

This becomes even more noticeable if you create an obstacle with very small polygons. 222 3333