| 1 |
<CsoundSynthesizer> |
| 2 |
<CsOptions> |
| 3 |
-odac ;activates real time sound output |
| 4 |
</CsOptions> |
| 5 |
<CsInstruments> |
| 6 |
|
| 7 |
sr = 44100 |
| 8 |
ksmps = 32 |
| 9 |
nchnls = 1 |
| 10 |
0dbfs = 1 |
| 11 |
|
| 12 |
instr 1 |
| 13 |
; -- generate an input audio signal (noise impulses) -- |
| 14 |
; repeating amplitude envelope: |
| 15 |
kEnv loopseg 1,0, 0,1,0.005,1,0.0001,0,0.9949,0 |
| 16 |
aSig pinkish kEnv*0.6 ; pink noise pulses |
| 17 |
|
| 18 |
; apply comb filter to input signal |
| 19 |
krvt linseg 0.1, 5, 2 ; reverb time |
| 20 |
alpt expseg 0.005,5,0.005,6,0.0005,10,0.1,1,0.1 ; loop time |
| 21 |
aRes vcomb aSig, krvt, alpt, 0.1 ; comb filter |
| 22 |
out aRes ; audio to output |
| 23 |
endin |
| 24 |
|
| 25 |
</CsInstruments> |
| 26 |
<CsScore> |
| 27 |
i 1 0 25 |
| 28 |
</CsScore> |
| 29 |
</CsoundSynthesizer> |
| 30 |
;example by Iain McCurdy |