Skip to content

sunyitong/FungalLight

Repository files navigation

FungalLight

中文 | English

Rust Bevy Paper arXiv License: MIT

A Bevy/Rust cellular-automata simulation for fungal morphology exploration and light-boundary containment, associated with the SIGGRAPH Asia 2024 Art Papers work Exploring Fungal Morphology Simulation and Dynamic Light Containment from a Graphics Generation Perspective.

Fungal simulation and light containment

What It Does

FungalLight simulates fungal spread on a 2D grid with local growth, resource consumption, restrictions, and light-like boundary feedback. It is a compact interactive prototype for exploring how fungal growth can be represented as a graphic time-series system.

The broader paper couples learned fungal spread dynamics with real-world light containment. This repository contains the Rust/Bevy simulation side: grid state, growth rules, visual feedback, and restriction-mask driven morphology.

Quick Start

git clone https://github.com/sunyitong/FungalLight.git
cd FungalLight
cargo run --release

The app opens a square Bevy window and starts the growth simulation from the configured initial position.

Controls

The current prototype runs automatically. Configuration is edited in src/init_data.rs:

Constant Meaning
CANVAS_SIZE Simulation grid size and window resolution.
RESTRICTION_IMAGE Image mask used to define growth boundaries.
FUNGI_INIT_POSITION Initial spawn point.
FUNGI_STEP_DISTANCE Maximum local growth step.
LIGHT_LIFE_TIME Duration of light feedback spawned at restricted boundaries.
*_COLOR Visual palette for living, dead, newborn, restricted, and light states.

Repository Layout

src/
  main.rs          Bevy app setup
  components.rs    ECS components and resources
  systems.rs       growth, spawning, restriction, and light systems
  init_data.rs     simulation constants
assets/images/     masks and visual assets
docs/assets/       README presentation images

Paper

Citation

If you use this repository or build on the simulation, please cite:

@inproceedings{Wang_2024,
  title={Exploring Fungal Morphology Simulation and Dynamic Light Containment from a Graphics Generation Perspective},
  DOI={10.1145/3680530.3695440},
  booktitle={SIGGRAPH Asia 2024 Art Papers},
  publisher={ACM},
  author={Wang, Kexin and He, Ivy and Li, Jinke and Asadipour, Ali and Sun, Yitong},
  year={2024},
  pages={1--8}
}

Development

cargo fmt
cargo clippy --all-targets --all-features
cargo test

License

This repository is released under the MIT License.

About

Rust/Bevy fungal morphology simulation for graphics, artificial life and dynamic light-containment research.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

 
 
 

Contributors