Debian Codegraph @

src/Examples/FLOSS Manual Examples/04 Sound Synthesis/04F06_grain3_random.csd

raw
1 <CsoundSynthesizer>
2 <CsOptions>
3 -odac
4 </CsOptions>
5 <CsInstruments>
6 sr = 44100
7 ksmps = 16
8 nchnls = 1
9 0dbfs = 1
10
11 ;waveforms used for granulation
12 giBuzz ftgen 1,0,4096,11,40,1,0.9
13
14 ;window function - used as an amplitude envelope for each grain
15 ;(bartlett window)
16 giWFn ftgen 2,0,16384,20,3,1
17
18 instr 1
19 kCPS = 100
20 kPhs = 0
21 kFmd transeg 0,21,0,0, 10,4,15, 10,-4,0
22 kPmd transeg 0,1,0,0, 10,4,1, 10,-4,0
23 kGDur = 0.8
24 kDens = 20
25 iMaxOvr = 1000
26 kFn = 1
27 ;print info. to the terminal
28 printks "Random Phase:%5.2F%TPitch Random:%5.2F%n",1,kPmd,kFmd
29 aSig grain3 kCPS, kPhs, kFmd, kPmd, kGDur, kDens, iMaxOvr, kFn, giWFn, 0, 0
30 out aSig*0.06
31 endin
32
33 </CsInstruments>
34 <CsScore>
35 i 1 0 51
36 e
37 </CsScore>
38 </CsoundSynthesizer>
39 ;example by Iain McCurdy