Skip to content

narasan49/bevy-fluid-sample

Repository files navigation

bevy fluid sample

This project is a fluid simulation sample built using the Bevy engine.

Try it on here!

Features

  • Invicid, incompressible 2D fluid simulation
  • One-way solid body to fluid interaction

Getting Started

To run the Bevy Fluid Sample, you will need to have Rust and Cargo installed on your system. Follow these steps to get up and running:

  1. Clone the repository:
git clone git@github.com:narasan49/bevy-fluid-sample.git
  1. Navigate to the project directory:
cd bevy-fluid-sample
  1. Build and run the project: I have some examples to demonstrate my fluid simulation:
    • Imposing forces with mouse and touch input (Also available here)

      cargo run --example interaction
      2024-08-15.134607.mp4
    • Solid-to-fluid feedback

      cargo run --example demo
      2024-08-15.134700.mp4

Acknowledgments

The simulation is inspired by and based on the algorithms described in these books:

I alse use Kenny assets for examples.