Originally reported by Sourceforge User: menno0
outrg does give the right results, but closes more than once with a memory invalid pointer error
example: <CsoundSynthesizer> <CsOptions> ; Select audio/midi flags here according to platform -odac ;;;realtime audio out ;-iadc ;;;uncomment -iadc if realtime audio input is needed too ; For Non-realtime ouput leave only the line below: ; -o outrg.wav -W ;;; for file output any platform </CsOptions> <CsInstruments>
sr = 44100 ksmps = 32 nchnls = 4 ;quad 0dbfs = 1
instr 1
kcps = p4
asig1 vco2 .5, 55 ;sawtooth1
asig2 vco2 .5, 110 ;sawtooth2
asig3 vco2 .5, 220 ;sawtooth3
asig4 vco2 .5, 440 ;sawtooth4
kstart randomh 1,4.99, kcps ;choose between 1 and 4
kstart = int(kstart)
printks "number of the first channel = %d\n",1/ p4+0.1, kstart ;decide what will be the start channel for asig1
outrg kstart, asig1, asig2, asig3, asig4 ;start with 55 Hz in channel1, 110 Hz in ch.2,
;220 Hz in ch.3, 440 Hz in ch.4
endin
</CsInstruments>
<CsScore>
i 1 0 10 1 i 1 11 5 30 e </CsScore> </CsoundSynthesizer>
该提问来源于开源项目:csound/csound