| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
A voxel-based fluid simulation engine for computer games
CubbyFlow is based on the Jet framework created by Doyub Kim. It provides matching 2-D and 3-D C++ and Python APIs for fluid simulation. Host code uses C++23; optional CUDA device code uses C++17.
Every simulator has both 2-D and 3-D implementations.
Set VCPKG_ROOT to your vcpkg checkout. CubbyFlow's manifest installs the required libraries during CMake configuration.
git clone https://github.com/utilForever/CubbyFlow.git
cd CubbyFlowFor macOS, Linux, or Windows Subsystem for Linux:
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DUSE_CUDA=OFF
cmake --build build --config ReleaseFor Windows:
cmake -S . -B build -A x64 -DUSE_CUDA=OFF
cmake --build build --config ReleaseRun an example:
./build/bin/HybridLiquidSimOn Windows, the executable is build\bin\Release\HybridLiquidSim.exe.
python -m pip install .docker pull cubbyflow/cubbyflow:latest
docker run -it cubbyflow/cubbyflow
# Inside the container:
/app/build/bin/HybridLiquidSimSee Documents/Install.md for platform-specific build, test, and installation instructions.
| Area | Paths |
|---|---|
| Public C++ API | Includes/Core/ |
| Core implementation | Sources/Core/ |
| Optional CUDA | Includes/Core/CUDA/, Sources/Core/CUDA/ |
| Python bindings | Includes/API/Python/, Sources/API/Python/ |
| Tests | Tests/ |
| Examples | Examples/ |
Most behavior starts in the core library and is shared by matching 2-D and 3-D APIs. Python bindings expose the same core types, while CUDA remains optional. See ARCHITECTURE.md for the full design and code-reading guide.
Build and run the focused CPU unit-test target:
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DUSE_CUDA=OFF -DBUILD_EXAMPLES=OFF -DBUILD_TESTS=ON
cmake --build build --target UnitTests --config Release
./build/bin/UnitTestsOn Windows, run build\bin\Release\UnitTests.exe. Contributor workflow, dimensional parity, Python/CUDA synchronization, and validation rules are documented in AGENTS.md.
Generated API reference and additional documentation are available on the project website.
Source code is available under Examples. These images were rendered with Mitsuba; more demos are on the project website.
| PCISPH | Level set | FLIP |
|---|---|---|
![]() |
![]() |
![]() |
| PIC | APIC |
|---|---|
![]() |
![]() |
| High viscosity | Low viscosity |
|---|---|
![]() |
![]() |
| Linear | Cubic spline |
|---|---|
![]() |
![]() |
Contributions are welcome through issues and pull requests. Read AGENTS.md for the repository's coding, testing, and review expectations before making a change.
You can contact me via e-mail (utilForever at gmail.com). I am always happy to answer questions or help with any issues you might have, and please be sure to share any additional work or your creations with me, I love seeing what other people are making.
CubbyFlow is licensed under the MIT License.
Copyright © 2017-2026 Chris Ohk
| Back | FazBrowse Home | New Git URL |