Configure FFmpeg Bass Filter Frequency and Gain

This article provides a straightforward guide on how to configure the cutoff frequency and gain using the FFmpeg bass audio filter. You will learn the syntax, the specific parameters required to adjust low-frequency levels, and practical command-line examples to boost or attenuate bass in your audio and video files.

The bass filter in FFmpeg is a shelving boost/cut filter that targets low-frequency audio. To configure it, you primarily manipulate two parameters: gain and frequency.

The Bass Filter Syntax

The basic syntax for the FFmpeg bass filter is:

-af "bass=g=GAIN:f=FREQUENCY"

Alternatively, you can use the short-form positional parameters:

-af "bass=GAIN:FREQUENCY"

Parameter Explanations

Practical Examples

1. Boosting Bass

To boost the bass by 8 dB for all frequencies below 80 Hz, use the following command:

ffmpeg -i input.mp3 -af "bass=g=8:f=80" output.mp3

2. Cutting Bass (Reducing Low-End Rumble)

To reduce low-end rumble by cutting frequencies below 120 Hz by 10 dB, use this command:

ffmpeg -i input.wav -af "bass=g=-10:f=120" output.wav

3. Using Shorthand Notation

If you omit the parameter names (g= and f=), FFmpeg expects the gain first, followed by the frequency:

ffmpeg -i input.mp4 -af "bass=5:150" output.mp4

Note: This boosts frequencies below 150 Hz by 5 dB while keeping the video track intact.