Ecasound Flanger and Chorus Native Effects Guide
This article provides an overview of how Ecasound implements flanging
and chorus effects through its native signal-processing operators. You
will learn the mechanics behind the primary time-modulated delay
operator (-efl), the theoretical distinction between
flanging and chorus in command-line audio processing, and how to
configure single-chain and multi-chain audio routes to generate both
classic comb-filtering and rich multi-voice modulation.
The Native
Time-Modulation Operator: -efl
Ecasound handles time-varying delay effects natively using the
flanger operator, specified on the command line or within chainsetup
scripts as -efl. The operator takes three primary
arguments:
-efl:delay_time,freq,amplitude
delay_time: The center delay time in milliseconds. This defines the baseline offset between the dry and wet audio signals.freq: The modulation frequency of the Low-Frequency Oscillator (LFO) in Hertz (Hz). This controls how rapidly the delay time oscillates.amplitude: The modulation depth in milliseconds. This determines how far the delay sweeps around the basedelay_time. The amplitude value must not exceed the base delay time, as negative delay is not physically realizable.
Under the hood, Ecasound maintains a ring buffer for the incoming audio samples. A sinusoidal LFO continuously modulates the read pointer's position relative to the write pointer based on the specified frequency and amplitude. The delayed, pitch-modulated signal is then summed with the dry direct signal.
Configuring Classic Flanging
Flanging relies on short delay times that produce constructive and destructive interference across the frequency spectrum, known as comb filtering. When the delay time modulates, these comb peaks and troughs sweep up and down the audible spectrum, creating the signature jet-plane swoosh.
To achieve standard flanging in Ecasound, set a short base delay between 1 and 5 milliseconds, a slow-to-moderate LFO speed (0.1 Hz to 1.0 Hz), and an amplitude close to the delay time:
ecasound -i input.wav -o output.wav -efl:3,0.5,2.5In this command:
- Base delay is set to 3 ms.
- The LFO modulates the signal at 0.5 Hz (one full sweep every two seconds).
- The sweep varies by ±2.5 ms, swinging the delay between 0.5 ms and 5.5 ms.
Implementing Chorus with
-efl
While flanging requires sub-10ms delays to trigger audible phase cancellation, a chorus effect simulates multiple instruments playing the same part simultaneously. This requires longer delay times (typically 15 to 40 milliseconds) to decouple the phase interaction, avoiding heavy comb filtering while introducing subtle pitch detuning (pitch modulation) via the LFO.
Because Ecasound does not include a separate distinct
-efc chorus operator, the native -efl engine
is repurposed for chorus by shifting these delay parameters:
ecasound -i input.wav -o output.wav -efl:25,0.8,3In this setup:
- A 25 ms delay avoids static hollow comb filtering.
- The 0.8 Hz LFO creates slow, natural movement.
- The 3 ms amplitude slightly fluctuates the pitch of the delayed voice without causing disorienting vibrato.
Multi-Voice Chorus via Parallel Routing
A single modulated delay line can sound thin compared to dedicated
hardware or multi-tap chorus units. Ecasound's native chain-routing
architecture allows you to construct a richer, multi-voice chorus by
splitting the input into parallel chains, applying asymmetrical
-efl settings to each, and panning the results:
ecasound -a:1,2 -i input.wav \
-a:1 -efl:20,0.6,2.5 -erc:1,2 -epp:20 \
-a:2 -efl:30,0.9,3.5 -erc:1,2 -epp:80 \
-a:1,2 -o output.wavThis configuration routes the input audio into two independent
processing chains (-a:1 and -a:2):
- Chain 1 applies a 20 ms delay modulated at 0.6 Hz,
panned toward the left channel (
-epp:20). - Chain 2 applies a 30 ms delay modulated at 0.9 Hz,
panned toward the right channel (
-epp:80). - Combining these unsynchronized LFOs and different delay anchors generates a dense, stereo-widened chorus effect entirely through native Ecasound operators.