repo.or.cz
/
chuck-blob.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
*** empty log message ***
[chuck-blob.git]
/
v2
/
test
/
33.ck
blob
13f15a6c20647c81d151af04f88bf12eea01a82c
1
// 33.ck : sine
2
3
// sine tones (fail-correct)
4
sinosc s => dac;
5
6
[ 0, 2, 4, 7, 9 ] @=> int f[];
7
8
// time loop
9
while( true )
10
{
11
// choose freq
12
std.mtof( f[math.rand2( 0, 4 )] + 72 ) => s.freq;
13
// advance time
14
100::ms => now;
15
}