blob: 5e800e0be476d1b66241598dd168481473ca1adb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
(use-modules (ice-9 match)
(srfi srfi-1)
(chickadee)
(chickadee math vector)
(chickadee render color)
(chickadee render shapes))
(define lines
(list-tabulate 48
(lambda (n)
(list (vec2 (random 640) (random 480))
(vec2 (random 640) (random 480))
(make-color (random:uniform)
(random:uniform)
(random:uniform)
1.0)
(1+ (random 16))))))
(define (draw alpha)
(for-each (match-lambda
((start end color thickness)
(draw-line start end
#:feather 1.5
#:color color
#:thickness thickness)))
lines))
(run-game/sdl #:draw draw)
|