Debian Codegraph @

examples/randi.csd

raw
1 <CsoundSynthesizer>
2 <CsOptions>
3 ; Select audio/midi flags here according to platform
4 -odac ;;;realtime audio out
5 ;-iadc ;;;uncomment -iadc if RT audio input is needed too
6 ; For Non-realtime ouput leave only the line below:
7 ; -o randi.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 ;same values every time
17
18 krnd randi 100, 10
19 printk .5, krnd ; look
20 aout oscili 0.8, 440+krnd, 1 ; & listen
21 outs aout, aout
22
23 endin
24
25 instr 2 ;different values every time
26
27 krnd randi 100, 10, 10 ; seed from system clock
28 printk .5, krnd ; look
29 aout oscili 0.8, 440+krnd, 1 ; & listen
30 outs aout, aout
31
32 endin
33 </CsInstruments>
34 <CsScore>
35 f 1 0 16384 10 1 ;sine wave.
36
37 i 1 0 1
38 i 2 2 1
39 e
40 </CsScore>
41 </CsoundSynthesizer>