Skip to content

sanjayyepuri/fluids

Repository files navigation

Fast Fluid Dynamics

Built with Rust+WASM and WebGL

About

For our final project we implemented an algorithm called Fast Fluid Dynamics (FFD) using Rust and WebGL. This is a method for creating real-time, stable fluid simulations that run entirely on the GPU based on Jos Stam’s paper, “Stable Fluids” (Stam 1999).

Our implementation is based on the tutorial in this GPU Gems Chapter.

🚴 Usage

🐑 Install dependencies

In order to use Rust and WASM you will need the nightly version of Rust.

  • First, install rustup
  • Then, run the following commands to install the rust nightly toolchain and make it the default:
$ rustup install nightly
$ rustup default nightly

You will also need to install Node.js. Then run the following command to install the javascript dependencies.

$ npm install

🛠️ Build

To build and run the project run the following command.

$ npm run serve

You can access the simulation from localhost:3000

To build without running the webserver execute:

$ npm run build

🔋 Batteries Included

About

A Fast Fluid Dynamics Implementation in Rust+WASM and WebGL

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE_APACHE
MIT
LICENSE_MIT

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors