Crate pixels_graphics_lib
source ·Expand description
Rust Graphics Lib
This is a simple wrapper around Pixels
, it provides basic shape, image and text rendering.
This boilerplate code is needed to use it:
struct Example {
}
impl System for Example {
fn update(&mut self, delta: &Timing) {
}
fn render(&mut self, graphics: &mut Graphics) {
}
}
fn main() -> Result<(), Box<dyn Error>> {
let system = Example {};
run(240, 160, "Doc Example", Box::new(system), Options::default())?;
Ok(())
}
Re-exports§
pub use buffer_graphics_lib;
Modules§
Macros§
- Update the position multiple views to be in a column if
gravity
is - Position and size a view relative to the parent or another view
- Update the position multiple views to be in a row if
gravity
is
Structs§
- Options for program windows
Enums§
Traits§
Functions§
- Helper method that sets up the screen and runs the loop
- Creates the window and pixels wrapper