phaseModulator

Not sure how to explain haha Just tried something out and it sounded nice.. (using two sine signals or a phasor at the modulation input). I guess, best way to describe would be something like a 'phase modulator', where the phase-shift is induced by the filter's cutoff frequency. It's not accurate, but at least it's something.. just try it out.. signal modulator based on a sine-mix between two filtered signals, which are being frequency modulated by the modulation input. The modulations for the 2 filtered signals are in 90 degree phase-offset. So you can also use the phasor oscillator to modulate the signal without creating harsh harmonics (the moment the phasor signal jumps from low to high, it's completely faded out, thus unhearable) connect "audio to be modulated" to the "in" input. connect a modulation oscillator to the PM input connect a modulation LFO/envelope to the pm input.
Author: Remco van der Most
License: BSD
Github: sss/fx/phaseModulator.axo

Inlets

frac32buffer input

frac32buffer PM

frac32 pm

Outlets

frac32buffer output

Parameters

frac32.u.map phase

Declaration
int32_t val01;
int32_t val02;
int32_t val03;
int32_t Phase;
int32_t phase;
int32_t phs01a;
int32_t phs02a;
int32_t fade;
int32_t ccompl;
int32_t f01;
int32_t f02;
Init
val01 = 0;
val02 = 0;
Audio Rate
val03 = val03 + ((param_phase + inlet_pm - val03) >> 12);
Phase = (inlet_PM + val03) & ((1 << 27) - 1);
phase = (Phase + (1 << 26)) & ((1 << 27) - 1);

SINE2TINTERP((Phase + (1 << 25)) << 5, fade)
fade = (fade >> 5) + (1 << 26);

ccompl = (1 << 27) - fade;

MTOF(Phase, f01);

MTOF(phase, f02);

val01 = ___SMMLA((inlet_in - val01) << 1, f01, val01);
phs01a = (val01 - inlet_in) + (val01);
val02 = ___SMMLA((inlet_in - val02) << 1, f02, val02);
phs02a = (val02 - inlet_in) + (val02);
outlet_out =
    ___SMMUL(fade << 3, phs02a << 2) + ___SMMUL(ccompl << 3, phs01a << 2);

Privacy

© 2024 Zrna Research