Debian Codegraph @

examples/table.csd

raw
1 <CsoundSynthesizer>
2 <CsOptions>
3 ; Select audio/midi flags here according to platform
4 ; Audio out Audio in
5 -odac ;;;realtime audio out
6 ; For Non-realtime ouput leave only the line below:
7 ; -o table.wav -W ;;; for file output any platform
8 </CsOptions>
9 <CsInstruments>
10
11 ; by Kevin Conder
12
13 sr = 44100
14 ksmps = 32
15 nchnls = 2
16 0dbfs = 1
17
18 instr 1
19
20 kndx line 0, p3, 1 ; Vary our index linearly from 0 to 1.
21
22 ifn = 1 ; Read Table #1 with our index.
23 ixmode = 1
24 kfreq table kndx, ifn, ixmode
25 a1 oscil .5, kfreq, 2; Generate a sine waveform, use our table values to vary its frequency.
26 outs a1, a1
27 endin
28
29 </CsInstruments>
30 <CsScore>
31 f 1 0 1025 -7 200 1024 2000 ; Table #1, a line from 200 to 2,000.
32 f 2 0 16384 10 1 ; Table #2, a sine wave.
33
34 i 1 0 2
35 e
36 </CsScore>
37 </CsoundSynthesizer>