Configure FFmpeg Lowpass Filter Cutoff and Poles
This guide explains how to configure the cutoff frequency and filter
poles using the FFmpeg lowpass audio filter. You will learn
the exact command-line syntax, the role of the frequency
and poles parameters, and practical examples to precisely
control high-frequency attenuation in your audio files.
The FFmpeg Lowpass Filter Syntax
The lowpass filter in FFmpeg passes frequencies below a
specified cutoff frequency and attenuates frequencies above it. To
configure this filter, you use the -af (audio filter) flag
with the lowpass filter name and its parameters:
ffmpeg -i input.mp3 -af "lowpass=f=2000:p=2" output.mp3Configuring the Cutoff Frequency (f)
The cutoff frequency determines the point at which the filter begins to reduce the audio signal’s volume.
Parameter:
frequencyorfValue: A double-precision floating-point number representing frequency in Hz (Hertz).
Default: 3000 Hz
Example: To set the cutoff frequency to 1000 Hz:
ffmpeg -i input.wav -af "lowpass=f=1000" output.wav
Configuring the Filter Poles (p)
The number of poles determines the steepness of the attenuation curve (the roll-off rate) past the cutoff frequency.
Parameter:
polesorpValue: An integer. Typically, the value is restricted to
1or2.Default: 2
Behavior:
- 1 Pole: Provides a shallower roll-off of 6 dB per octave. This results in a gentler, more natural reduction of high frequencies.
- 2 Poles: Provides a steeper roll-off of 12 dB per octave. This blocks high frequencies more aggressively.
Example: To set a steep 2-pole filter:
ffmpeg -i input.wav -af "lowpass=p=2" output.wav
Combining Parameters in a Single Command
To customize both the frequency and the poles simultaneously,
separate the arguments with a colon (:).
Example 1: Gentle High-Cut at 4 kHz
This command attenuates frequencies above 4000 Hz with a gentle 1-pole curve (6 dB/octave):
ffmpeg -i input.wav -af "lowpass=f=4000:p=1" output.wavExample 2: Aggressive Bass-Pass at 500 Hz
This command cuts off everything above 500 Hz with a steep 2-pole curve (12 dB/octave), leaving mostly low-end frequencies:
ffmpeg -i input.wav -af "lowpass=f=500:p=2" output.wav