Debian Codegraph @

src/Examples/FLOSS Manual Examples/03 Csound Language/03A18_Zipper.csd

raw
1 <CsoundSynthesizer>
2 <CsOptions>
3 -o dac
4 </CsOptions>
5 <CsInstruments>
6 sr = 44100
7 ;--- increase or decrease to hear the difference more or less evident
8 ksmps = 128
9 nchnls = 2
10 0dbfs = 1
11
12 instr 1 ;envelope at k-time
13 aSine poscil .5, 800
14 kEnv transeg 0, .1, 5, 1, .1, -5, 0
15 aOut = aSine * kEnv
16 outs aOut, aOut
17 endin
18
19 instr 2 ;envelope at a-time
20 aSine poscil .5, 800
21 aEnv transeg 0, .1, 5, 1, .1, -5, 0
22 aOut = aSine * aEnv
23 outs aOut, aOut
24 endin
25
26 instr 3 ;envelope at k-time with a-time interpolation
27 aSine poscil .5, 800
28 kEnv transeg 0, .1, 5, 1, .1, -5, 0
29 aOut = aSine * a(kEnv)
30 outs aOut, aOut
31 endin
32
33 </CsInstruments>
34 <CsScore>
35 r 3 ;repeat the following line 3 times
36 i 1 0 1
37 s ;end of section
38 r 3
39 i 2 0 1
40 s
41 r 3
42 i 3 0 1
43 </CsScore>
44 </CsoundSynthesizer>
45 ;example by joachim heintz