A cross platform C++ fluid simulation using WebGPU. Uses MLS-MPM to perform the simulation.
- cmake
- emscripten (if building for web)
brew install cmake emscripten
git clone https://github.com/connor-ms/simulator.git
cd simulator
git submodule update --init
mkdir build
cmake -B build
cmake --build build -j4
./build/app
mkdir build-web
emcmake cmake -B build-web
cmake --build build-web -j4
npx http-server
Then open http://127.0.0.1:8080 in your browser and navigate to build-web/app.html.
Note that building for web has not been tested recently. This has primarily been tested on Mac, but should work on other platforms/web.