Multiwindow example now creates a third window

This commit is contained in:
Pierre Krieger 2014-08-07 18:15:09 +02:00
parent 01fd8b1d9e
commit da5e372719

View file

@ -5,6 +5,7 @@ extern crate gl;
fn main() { fn main() {
let window1 = init::Window::new().unwrap(); let window1 = init::Window::new().unwrap();
let window2 = init::Window::new().unwrap(); let window2 = init::Window::new().unwrap();
let window3 = init::Window::new().unwrap();
spawn(proc() { spawn(proc() {
run(window1, (0.0, 1.0, 0.0, 1.0)); run(window1, (0.0, 1.0, 0.0, 1.0));
@ -13,6 +14,10 @@ fn main() {
spawn(proc() { spawn(proc() {
run(window2, (0.0, 0.0, 1.0, 1.0)); run(window2, (0.0, 0.0, 1.0, 1.0));
}); });
spawn(proc() {
run(window3, (1.0, 0.0, 0.0, 1.0));
});
} }
fn run(window: init::Window, color: (f32, f32, f32, f32)) { fn run(window: init::Window, color: (f32, f32, f32, f32)) {