frac32buffer in2
frac32 cut
frac32 res
int32 MT
frac32buffer out
bool32.tgl allpass
bool32.tgl add
frac32.s.map.pitch cut
frac32.u.map.filterq res
int32.hradio mode
int32.hradio type
objref core
int i;
biquad_state bs;
biquad_coefficients bc;
int32_t in[BUFSIZE];
int32_t out[BUFSIZE];
int32_t val[8];
int32_t freq;
int32_t pv;
int32_t stp;
int32_t Freq;
int prv;
int32_t v26 = (1 >> 26);
int BUFMASK = BUFSIZE - 1;
int32_t band;
int32_t low;
attr_core.bs = bs;
attr_core.bc = bc;
attr_core.low = low;
attr_core.band = band;
for (i = 0; i < BUFSIZE; i++) {
attr_core.in[i] = inlet_in[i];
}
attr_core.ALL = (param_allpass + ((inlet_MT >> 4) & 1)) & 1;
int MODE = ((param_mode & 3) + ((param_type & 3) << 2) + inlet_MT) & 15;
if (!(MODE == prv)) {
for (i = 0; i < 8; i++) {
val[i] = 0;
}
}
attr_core.settings(__SSAT(param_cut + inlet_cut, 28),
__USAT(param_res + inlet_res, 27), MODE);
Freq = attr_core.Freq;
if ((MODE < 8) || (MODE > 11)) {
stp = (Freq - pv) >> 4;
freq = pv;
pv = Freq;
} else {
freq = Freq;
}
attr_core.freq = freq;
attr_core.stp = stp;
for (i = 0; i < 8; i++) {
attr_core.val[i] = val[i];
}
attr_core.filter(MODE);
for (i = 0; i < 8; i++) {
val[i] = attr_core.val[i];
}
for (i = 0; i < BUFSIZE; i++) {
int32_t tmp =
__SSAT(attr_core.out[i], 28) + (param_add > 0 ? inlet_in[i] : 0);
int32_t ts = __SSAT(tmp, 28);
int32_t tsq31 = ts << 3;
int32_t tsq31p3 = ___SMMUL(tsq31, ___SMMUL(tsq31, tsq31));
outlet_out[i] = ts + (ts >> 1) - (tsq31p3);
}
prv = MODE;
bs = attr_core.bs;
bc = attr_core.bc;
low = attr_core.low;
band = attr_core.band;