add "force mono audio" option and fix flags not be

ing set after a dispatch reset
This commit is contained in:
tildearrow 2022-02-04 17:04:36 -05:00
parent 16f497fcf1
commit a93a9c19f3
6 changed files with 22 additions and 3 deletions

View file

@ -1192,5 +1192,12 @@ void DivEngine::nextBuf(float** in, float** out, int inChans, int outChans, unsi
memcpy(oscBuf[0],out[0],size*sizeof(float));
memcpy(oscBuf[1],out[1],size*sizeof(float));
oscSize=size;
if (forceMono) {
for (size_t i=0; i<size; i++) {
out[0][i]=(out[0][i]+out[1][i])*0.5;
out[1][i]=out[0][i];
}
}
isBusy.unlock();
}