IO Variants: 2
Variant: 1
frac32.bipolar Pitch input
frac32.bipolar Phase input
bool32.rising Reset phase
frac32.bipolar Sine wave
frac32.s.map.lfopitch pitch
uint32_t phase;
int32_t old_reset;
phase = 0;
old_reset = 0;
if (inlet_reset && !old_reset) {
phase = 0;
} else {
int32_t freq;
MTOFEXTENDED(param_pitch + inlet_pitch, freq);
phase += freq >> 2;
}
old_reset = inlet_reset;
int32_t sine;
SINE2TINTERP(phase + (inlet_phase << 4), sine)
outlet_sine = (sine >> 4);
Variant: 2
frac32.bipolar Pitch input
frac32.bipolar Phase input
bool32.rising Reset phase
frac32.positive Sine wave
frac32.s.map.lfopitch pitch
uint32_t phase;
uint32_t old_reset;
phase = 0;
old_reset = 0;
if (inlet_reset && !old_reset) {
phase = 0;
} else {
int32_t freq;
MTOFEXTENDED(param_pitch + inlet_pitch, freq);
phase += freq >> 2;
}
old_reset = inlet_reset;
int32_t sine;
SINE2TINTERP(phase + (inlet_phase << 4), sine)
outlet_sine = (sine >> 5) + (1 << 26);