release-packaging/Classes/FluidNRTProcess.sc: Reintroduce a sync at the cost of performance, but the benefit of being sure that buffers have updated before action is called

nix
Owen Green 6 years ago
parent abc9dadbce
commit 52ddb8b21d

@ -21,6 +21,7 @@ FluidNRTProcess : Object{
^this; ^this;
} }
process{|...ugenArgs| process{|...ugenArgs|
var c = Condition.new(false); var c = Condition.new(false);
@ -31,13 +32,16 @@ FluidNRTProcess : Object{
synth.postln; synth.postln;
OSCFunc({ |m| OSCFunc({ |m|
forkIfNeeded{
outputBuffers.do{|buf| outputBuffers.do{|buf|
buf = server.cachedBufferAt(buf.asUGenInput); buf = server.cachedBufferAt(buf.asUGenInput);
buf.updateInfo; buf.updateInfo;
}; };
server.sync;
if(action.notNil && m[2]==0){action.valueArray(outputBuffers)}; if(action.notNil && m[2]==0){action.valueArray(outputBuffers)};
c.test = true; c.test = true;
c.signal; c.signal;
}
},'/done',argTemplate:[synth.nodeID]).oneShot; },'/done',argTemplate:[synth.nodeID]).oneShot;
forkIfNeeded{ forkIfNeeded{

Loading…
Cancel
Save