Hey guys, ive worked with Csound abit before and using it again
I am using the Csound~ object loading QuietCsound in Maxmsp and running my score from there.
Csound~ allows for multiple audio outs.
so if im doing 6 channels, i want to have different instruments outputting to different channels, now ive set my nchnls = 6 and ive tried using outch but either im not using the right arguments or becasue i actually dont have 6 physical channels on my soundcard it wont let me.
so heres my code working with 2 outs
; Select audio/midi flags here according to platform
; Audio out Audio in No messages
-odac -iadc -d ;;;RT audio I/O
; For Non-realtime ouput leave only the line below:
; -o granule.wav -W ;;; for file output any platform
sr = 44100
kr = 4410
ksmps = 10
nchnls = 2
instr 1
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a1 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a2 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outs a1,a2
endin
instr 2
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a1 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a2 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outs a1,a2
endin
instr 3
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a1 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a2 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outs a1,a2
endin
instr 4
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a1 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a2 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outs a1,a2
endin
; f statement read sound file mary.wav in the SFDIR
; directory into f-table 1
f0 0 9
f1 0 262144 1 "audio1.aif" 0 0 0
f2 0 262144 1 "audio2.aif" 0 0 0
; p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,p16,p17,p18,p19,p20,p21,p22,p23,p24
i1 0 100 2000 64 0.5 1 0 1 4 0 0.005 5 0.01 50 0.02 50 30 30 0.39 1 1.42 0.29 2
i2 0 100 0 64 0.5 1 0 2 4 0 0.005 5 0.01 50 0.02 50 30 30 0.39 1 1.42 0.29 2
e
and what i tried for 6
; Select audio/midi flags here according to platform
; Audio out Audio in No messages
-odac -iadc -d ;;;RT audio I/O
; For Non-realtime ouput leave only the line below:
; -o granule.wav -W ;;; for file output any platform
sr = 44100
kr = 4410
ksmps = 10
nchnls = 6
instr 1
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a1 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a2 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outch a1,a2, 0, 0, 0, 0
endin
instr 2
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a3 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a4 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outs 0, 0, a3, a4, 0, 0
endin
instr 3
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a1 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a2 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outch a1,a2,0,0,0,0
endin
instr 4
;
k1 linseg 0,0.5,1,(p3-p2-1),1,0.5,0
a5 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19,p20,p21,p22,p23,p24
a6 granule p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,\
p16,p17,p18,p19, p20+0.17,p21,p22,p23,p24
outch 0,0,0,0,a5,a6
endin
; f statement read sound file mary.wav in the SFDIR
; directory into f-table 1
f0 0 9
f1 0 262144 1 "audio1.aif" 0 0 0
f2 0 262144 1 "audio2.aif" 0 0 0
; p4*k1,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,p16,p17,p18,p19,p20,p21,p22,p23,p24
i1 0 100 2000 64 0.5 1 0 1 4 0 0.005 5 0.01 50 0.02 50 30 30 0.39 1 1.42 0.29 2
i2 0 100 0 64 0.5 1 0 2 4 0 0.005 5 0.01 50 0.02 50 30 30 0.39 1 1.42 0.29 2
e
so is my code wrong?
or do i need 6 actually outs on my hardware for it to work in maxmsp
thanks


