How to Normalize Audio to 0 dBFS in Ecasound
Normalizing audio amplitude to zero decibels full scale (0 dBFS) in
Ecasound requires using the volume analysis operator,
-ev, in combination with the amplification
operator, -ea. Because Ecasound is
designed as a real-time, stream-based audio processor, it does not scan
ahead in a single pass to automatically normalize peak levels. Instead,
peak normalization to 0 dBFS is achieved through a standard two-step
process: analyzing the signal with -ev to determine the
maximum peak and required gain, then applying that gain with
-ea.
The Operators Explained
The Analysis Operator:
-ev
The -ev (envelope volume) operator analyzes the audio
stream and outputs statistical volume data without altering the audio.
When executed on an audio file, it calculates:
- Peak amplitude
- RMS amplitude
- The exact multiplier factor required to scale the highest peak to 0 dBFS (100% amplitude)
The Amplification Operator:
-ea
The -ea:multiplier operator applies linear amplification
across all channels. The parameter represents an amplitude scaling
factor (where 100 represents 100% / unity gain, and values
above or below amplify or attenuate accordingly).
Step-by-Step Normalization Process
Step 1: Analyze the Peak Level
Run Ecasound with the -ev operator directed to null
output to inspect the file:
ecasound -i input.wav -evAt the end of processing, Ecasound outputs volume statistics in the terminal, including a line indicating the peak amplitude and the required scaling value:
(eca-chainsetup) Volume analysis results:
...
-- multiplier for max peak: 1.45 (or percentage equivalent)
Step 2: Apply the Normalization Gain
Take the calculated multiplier and apply it using -ea to
render the normalized file:
ecasound -i input.wav -o output.wav -ea:145If the output provides a direct percentage or floating-point multiplier, adjust the parameter so the peak reaches exactly 1.0 (100% / 0 dBFS).
Alternative:
Real-Time Peak Limiting with -eal
If dynamic peak control is needed in a single real-time stream rather
than two-pass linear normalization, Ecasound provides the
-eal:max-limit-% operator.
ecasound -i input.wav -o output.wav -eal:100Setting -eal:100 restricts the maximum signal amplitude
to 100% (0 dBFS). However, -eal operates as a limiter
(compressing or clipping peaks that exceed the threshold) rather than
applying uniform gain adjustment across the entire recording. For true
linear normalization to 0 dBFS without altering dynamics, the
-ev and -ea workflow remains the correct
approach.