Sorry, I think I’m being confusing - the point I’m trying to make is the two voices are not stable. If I run just the following:
b = Bus.audio(s);
(
c = {var input = In.ar(b);
var sines = FluidSineFeature.kr(input,5);
var voices = FluidVoiceAllocator.kr(sines[0], sines[1], 6);
SendReply.kr(Impulse.kr(1),"/sourcesines", [sines ++ voices].flat);
input.dup;
}.play;
)
(
o = OSCFunc({
arg msg;
"freqI + magI ".post; msg[3..12].round(0.01).postln;
"freqO + magO ".post; msg[13..24].round(0.01).postln;
"voice states ".post; msg[25..].round(1).postln;
"\n".postln
},"/sourcesines");
)
d = {Out.ar(b,SinOsc.ar(440,mul: 0.1))}.play
e = {Out.ar(b,SinOsc.ar(550,mul: 0.05))}.play
The server spits out:
-> Synth('temp__13' : 1013) // this is the server returning e.play
freqI + magI [ 441.97, 0.0, 0.0, 0.0, 0.0, 0.1, 0.0, 0.0, 0.0, 0.0 ] // second voice doesn't appear here
freqO + magO [ 441.97, 541.81, 0.0, 0.0, 0.0, 0.0, 0.1, 0.05, 0.0, 0.0, 0.0, 0.0 ] // but it shows up here?
voice states [ 2.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] // but not here!
freqI + magI [ 441.37, 543.08, 0.0, 0.0, 0.0, 0.1, 0.05, 0.0, 0.0, 0.0 ] // oops, there it is!
freqO + magO [ 441.37, 546.63, 544.46, 543.08, 543.75, 541.81, 0.1, 0.05, 0.05, 0.05, 0.05, 0.05 ] // oh, but in the previous second it's been allocated to five voices?
voice states [ 2.0, 0.0, 0.0, 2.0, 0.0, 0.0 ] // but it seems to have settled on index 3!
freqI + magI [ 440.61, 548.09, 0.0, 0.0, 0.0, 0.1, 0.05, 0.0, 0.0, 0.0 ]
freqO + magO [ 440.61, 542.43, 545.17, 543.08, 541.22, 548.09, 0.1, 0.05, 0.05, 0.05, 0.05, 0.05 ]
voice states [ 2.0, 0.0, 0.0, 0.0, 0.0, 2.0 ] // oh wait, nevermind!
freqI + magI [ 441.97, 0.0, 0.0, 0.0, 0.0, 0.1, 0.0, 0.0, 0.0, 0.0 ] // wait, where did it go?
freqO + magO [ 441.97, 541.81, 543.08, 541.22, 545.9, 543.76, 0.1, 0.05, 0.05, 0.05, 0.05, 0.05 ]
voice states [ 2.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] // gone here too...
Which to me doesn’t seem stable - unless this is expected/intended behaviour…in which case I’ve misunderstood something and apologize for the confusion!