Shader Chronicles: The Highs and Lows of Real-Time Fluid Motion


This shader has been proven to be difficult. So far I have managed to recreate the fluid simulation following the research done by Patrick O'Brien in his master thesis on digital watercolor. His work take a deep dive on the use of the GPU for the Lattice Boltzman Method (LBM), which has been the favorite method of many researchers when it comes to fluid simulation because it is an optimization over the Navier Stokes equation.

Base Texture

The picture above shows the base texture used for debugging purposes. The mishaps I have encountered relate to the desired effect. I have managed to make the uv move around in a fluid like manner in response to the input, but some colors from distant parts of the shader get involved with the collision area. The image below is the result.


I found a way to get around this problem by playing with the velocity values, however, when I solve the problem of the colors what happens is that the texture's uv's barely move. It still looks like a fluid, but the colors don't move far along so it gets back to its original position quite fast, like shown in the picture below.


Will keep you posted with any development and breakthrough.

Leave a comment

Log in with itch.io to leave a comment.