Fun with the Rust programming language - maze generation, path finding and visualisation with SDL.
- Install Rust 1.85+ (Rust 2024 edition).
On unix/posix family systems install the C libraries:
- libsdl2-dev >= 2.1.4
- libsdl2-ttf-dev
- libsdl2-image-dev
On windows and unix/posix install the tool:
- gcc
GCC is probably already installed on posix! For windows see e.g. mingw-w64 or mingw-w64 chocolatey.
Future updates may use the static/bundled compilation feature of the Rust SDL2 create, which requires a C compiler,
at which point the build.rs file and pre-compiled SDL libs for Windows will not be required and neither will these C
library installations on Linux be required.
Use the mazes driver executable to try out the mazes library. The commandline interface is built with docopt.
cargo run -- --help
# Examples
cargo run -- render recursive-backtracker image --grid-width=140 --grid-height=80 --mark-start-end --colour-distances --show-path
cargo run -- render wilson text image --text-out="maze.text" --grid-size=40