aboutsummaryrefslogtreecommitdiff
path: root/music.scm
blob: a45111fb051f3869daf23f251c9eb83827ecc920 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
(include "lib.scm")

(define (melody t) (+
	((note (getfreq 3 4) 0 1/4) t)
	((note (getfreq 3 8) 1/4 1/4) t)
	((note (getfreq 3 4) 3/4 1/4) t)
	((note (getfreq 3 11) 1 1/4) t)
	((note (getfreq 3 4) 5/4 1/4) t)
	((note (getfreq 3 2) 3/2 1/4) t)
	((note (getfreq 3 8) 7/4 1/4) t)
	((note (getfreq 3 4) 9/4 1/4) t)
	((note (getfreq 3 11) 5/2 1/4) t)
	((note (getfreq 3 4) 11/4 1/4) t)
))

(define (music t) (
	melody (floor-remainder t 3)
))