~irimi1/nannou-experiments

ref: 036156495f981f599e68820a6ade242d3ddfec02 nannou-experiments/fiddling/unu/src/main.rs -rw-r--r-- 376 bytes
03615649Manuel Groß Add license 1 year, 4 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* https://guide.nannou.cc/tutorials/basics/draw-a-sketch.html */

use nannou::prelude::*;

fn main() {
    nannou::sketch(view).run();
}

fn view(app: &App, frame: Frame){
    // get canvas to draw on
    let draw = app.draw();

    // set background to blue
    draw.background().color(PURPLE);

    // put everything on the frame
    draw.to_frame(app, &frame).unwrap();
}