Sophie

Sophie

distrib > Mageia > 5 > x86_64 > media > core-release > by-pkgid > b707d9a4ee443103660a75ccb6e51334 > files > 2486

csound-doc-5.19.01-10.mga5.noarch.rpm

<CsoundSynthesizer>
<CsOptions>
-d -odac -iadc -B2048 -b1024
</CsOptions>
<CsInstruments>
sr=44100
ksmps=128
nchnls=1

gklevel chnexport "meter",3
gkp chnexport "pitch", 3

instr 1
k10 chnget "clicked"

if k10 == 0 then
a1 in
ks rms a1
kp,ka pitchamdf a1,55,660 
gklevel = ks
if gklevel > 500 then
gkp = (kp-55)/660
else
gkp = 0.5
gklevel = 0
endif
kl tonek gklevel, 10
kp tonek kp, 10
else
kl tonek gklevel, 10
kp tonek gkp, 10
endif

asig oscili kl, kp, 1
 out asig

endin

</CsInstruments>
<CsScore>

f1 0 16384 10 1 .5 .3 .2 .1 .05
i1 0 360000
e
</CsScore>
</CsoundSynthesizer>