Piston Examples
A collection of examples using the Piston game engine
How to build & run examples
To build the examples, you need Rust and Cargo installed.
- Install Rustlang for example through rustup
- Invoke
cargo run --example <NAME>
where theNAME
are a file names fromexamples
directory 2.1. Optionally navigate toexamples/<directory>
and invokecargo run
for more complex examples
Troubleshooting
-
I get "GL context creation failed" when running an example.
It's likely your hardware or driver doesn't support PistonWindow's default OpenGl spec. Just change it to something you can support at the beginning of the example. See hello_world.rs for an example.