#glfw #window #piston

pistoncore-glfw_window

A GLFW window back-end for the Piston game engine

71 breaking releases

Uses old Rust 2015

new 0.71.0 Jan 12, 2021
0.70.0 Nov 8, 2020
0.69.0 Nov 8, 2020
0.67.0 Jul 18, 2020
0.0.7 Feb 24, 2015

#346 in Game dev

Download history 43/week @ 2020-09-23 114/week @ 2020-09-30 42/week @ 2020-10-07 47/week @ 2020-10-14 96/week @ 2020-10-21 42/week @ 2020-10-28 87/week @ 2020-11-04 66/week @ 2020-11-11 47/week @ 2020-11-18 112/week @ 2020-11-25 50/week @ 2020-12-02 185/week @ 2020-12-09 12/week @ 2020-12-16 21/week @ 2020-12-23 22/week @ 2020-12-30 45/week @ 2021-01-06

275 downloads per month
Used in rsui

MIT license

58KB
448 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–3MB
~66K SLoC