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]
/
examples
/
imp.ck
blob
c3974582b82393ac08665106eddc4e0dfb1e9704
1
// impulse generator is cool...
2
// this demo is not
3
4
// connect impulse generator
5
impulse i => dac;
6
.5 => i.gain;
7
8
// emit impulse every so often
9
2000 => int a;
10
while( 1 )
11
{
12
// set the next sample
13
1.0 => i.next;
14
15
// advance time
16
a::samp => now;
17
a - 8 => a; if( a <= 0 ) 2000 => a;
18
}