#glfw #window #piston

pistoncore-glfw_window

A GLFW window back-end for the Piston game engine

80 breaking releases

Uses old Rust 2015

0.80.0 Nov 14, 2023
0.78.0 Feb 25, 2023
0.77.0 Nov 16, 2022
0.75.0 Feb 23, 2022
0.0.7 Feb 24, 2015

#149 in Hardware support

Download history 86/week @ 2023-10-20 225/week @ 2023-10-27 97/week @ 2023-11-03 167/week @ 2023-11-10 93/week @ 2023-11-17 250/week @ 2023-11-24 298/week @ 2023-12-01 75/week @ 2023-12-08 168/week @ 2023-12-15 237/week @ 2023-12-22 39/week @ 2023-12-29 153/week @ 2024-01-05 82/week @ 2024-01-12 146/week @ 2024-01-19 134/week @ 2024-01-26 109/week @ 2024-02-02

481 downloads per month
Used in 2 crates

MIT license

59KB
568 lines

glfw_window Build Status

A GLFW window back-end for the Piston game engine.

Maintainers: @TyOverby, @bvssvni, @Coeuvre

How to contribute

How to create a window

let mut window: GlfwWindow = WindowSettings::new("GLFW Window", (640, 480))
    .fullscreen(false)
    .vsync(true)
    .build()
    .unwrap();

See the examples for more ways to create a window.

How to set up Gfx

After you have created a window, do the following:

let mut device = gfx::GlDevice::new(|s|
    self.window.get_proc_address(s)
);
let (w, h) = window.get_size();
let frame = gfx::Frame::new(w as u16, h as u16);

Troubleshooting

Dependencies

dependencies


lib.rs:

A GLFW window back-end for the Piston game engine.

Dependencies

~2.3–3.5MB
~71K SLoC