| 1 |
<CsoundSynthesizer> |
| 2 |
<CsOptions> |
| 3 |
; Select audio/midi flags here according to platform |
| 4 |
-odac ;;;realtime audio out |
| 5 |
;-iadc ;;;uncomment -iadc if realtime audio input is needed too |
| 6 |
; For Non-realtime ouput leave only the line below: |
| 7 |
; -o gain.wav -W ;;; for file output any platform |
| 8 |
</CsOptions> |
| 9 |
<CsInstruments> |
| 10 |
|
| 11 |
sr = 44100 |
| 12 |
ksmps = 32 |
| 13 |
nchnls = 2 |
| 14 |
0dbfs = 1 |
| 15 |
|
| 16 |
instr 1 |
| 17 |
|
| 18 |
asrc buzz .8, 440, sr/440, 1 ; band-limited pulse train. |
| 19 |
a1 reson asrc, 1000, 100 ; Sent through |
| 20 |
a2 reson a1, 3000, 500 ; 2 filters |
| 21 |
krms rms asrc ; then balanced |
| 22 |
afin gain a2, krms ; with source |
| 23 |
outs afin, afin |
| 24 |
endin |
| 25 |
|
| 26 |
|
| 27 |
</CsInstruments> |
| 28 |
<CsScore> |
| 29 |
;sine wave. |
| 30 |
f 1 0 16384 10 1 |
| 31 |
|
| 32 |
i 1 0 2 |
| 33 |
e |
| 34 |
</CsScore> |
| 35 |
</CsoundSynthesizer> |