Hi Yann, On 08/21, Yann Orlarey wrote: > > A *very* experimental implementation of the ondemand primitive is available > here : > > https://github.com/grame-cncm/faust/tree/experimental-ondemand > > The implementation is currently only available for -lang ocpp in scalar > mode. Here are some simple examples :
Am I understand correctly? Currently process = (clk : ondemand(sig)); acts the same as process = control(sig,clk); right? ------------------------------------------------------------------------------- and it seems it has the same problem: clk = ffunction(int clk(), "",""); sig = ffunction(float sig(), "",""); process = (clk : ondemand(sig)); compiles to virtual void compute (int count, FAUSTFLOAT** input, FAUSTFLOAT** output) { //zone1 //zone2 float fTemp0 = fTempPerm0; //zone2b //zone3 FAUSTFLOAT* output0 = output[0]; //LoopGraphScalar for (int i=0; i<count; i++) { if (clk()) { fTemp0 = sig(); } output0[i] = (FAUSTFLOAT)fTemp0; } fTempPerm0 = fTemp0; } and this looks correct. However, process = (clk : ondemand(sig)), sig; results in virtual void compute (int count, FAUSTFLOAT** input, FAUSTFLOAT** output) { //zone1 //zone2 //zone2b //zone3 FAUSTFLOAT* output0 = output[0]; FAUSTFLOAT* output1 = output[1]; //LoopGraphScalar for (int i=0; i<count; i++) { float fTemp0 = sig(); output0[i] = (FAUSTFLOAT)fTemp0; output1[i] = (FAUSTFLOAT)fTemp0; } } and this doesn't look right... Thanks! Oleg. _______________________________________________ Faudiostream-users mailing list Faudiostream-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/faudiostream-users