AudioGraphBuilder.lrPhaseCorrect() method
Manual L/R phase corrector — bring an out-of-phase left/right pair back into phase. Two operator-driven controls (drive them live via setParams while watching the correlation meter): - invertLeft / invertRight: flip that channel’s polarity (fixes the ~180° fault where the pair cancels when summed to mono). - skewMs: delay one channel to line the pair up in time — > 0 delays the right channel, < 0 the left (whole-sample delay; latency = |skew|). With corrWindowMs > 0 the node emits a correlation reading of the corrected output every window (0 = off) so the UI can show it trending to +1. Only channels 0/1 (L/R) are affected; further channels pass through.
Signature:
lrPhaseCorrect(input: AudioNode, opts?: {
invertLeft?: boolean;
invertRight?: boolean;
skewMs?: number;
corrWindowMs?: number;
name?: string;
}): AudioNode;