/dcgrid

DCGrid: An Adaptive Grid Structure for Memory-Constrained Fluid Simulation on the GPU

Primary LanguageCudaGNU General Public License v3.0GPL-3.0

DCGrid

Please note: The project won't run out of the box. For managing the window, UI, user input, etc. A proprietary library was used, which I can't include here. Only main.cpp and simulation.* are affected. I'd be happy to accept a PR that allows this project to run without the library. If you're interested in helping out, feel free to reach out for any questions.

Prerequisites

  • Visual Studio 2019
  • CUDA v11.1 or later
  • VCPKG
  • C++ boost

Installation

  1. Clone the repository
  2. Open the repository in Visual Studio
  3. Run the project in Visual Studio (Preferably in "Release" or "Release with debug symbols" mode)

Controls

Key Description
N Switch between uniform and adaptive simulation
H Reset simulation
Space Toggle Pause / Running
T Toggle terrain debugging
1 Set render mode: normal
2 Set render mode: pressure
3 Set render mode: temperature
4 Set render mode: resolution
5 Set render mode: vapor
6 Set render mode: velocity
W S A D Move camera
Mousewheel Move camera back and forth

Explore the UI for further interactions.

Related paper