C.W.K.
Stream
Lesson 04 of 10 · published

Volume Adjustment

~8 min · volume, gain, loud, quiet

Level 0Viewer
0 XP0/73 lessons0/15 achievements
0/100 XP to next level100 XP to go0% complete

Three filters that all change volume

  • volume — multiplies samples by a factor. Simple, immediate.
  • volumedetect — analyzes peaks/RMS without modifying anything. Use this first.
  • loudnorm — broadcast-grade loudness normalization (EBU R128). The right tool for podcasts/YouTube. Lesson 5.

Decibel math

volume=2.0 = +6 dB. volume=0.5 = -6 dB. volume=1.5dB works too — FFmpeg parses dB suffix. volume=-3dB halves perceived loudness.

The headroom rule

Don't blindly boost a clip to peak at 0 dBFS — modern podcasts target -16 LUFS integrated loudness with -1 dBTP true peak. Hitting 0 dBFS means inter-sample peaks clip on conversion to MP3/AAC. Lesson 5's loudnorm handles this correctly.

Code

Volume — measure and adjust·bash
# Measure (no output, just stats)
ffmpeg -i in.wav -af volumedetect -vn -f null - 2>&1 | grep -E 'mean|max'
# [Parsed_volumedetect_0 @ 0x...] mean_volume: -23.4 dB
# [Parsed_volumedetect_0 @ 0x...] max_volume: -6.7 dB

# Boost by 6 dB
ffmpeg -i in.wav -af "volume=6dB" out.wav

# Cut by 3 dB
ffmpeg -i in.wav -af "volume=-3dB" out.wav

# Multiply by 1.5x (≈ +3.5 dB)
ffmpeg -i in.wav -af "volume=1.5" out.wav
Per-channel volume·bash
# Boost left channel only +6 dB
ffmpeg -i in.wav -af "volume=6dB:enable=between(c,0,0)" out.wav

# Or use pan with a multiplier
ffmpeg -i in.wav -af "pan=stereo|c0=2.0*c0|c1=c1" out.wav

External links

Exercise

Take a quiet recording. Run volumedetect and note mean and max volume. Boost the file to bring max_volume up to about -1 dB (compute the boost yourself). Listen and confirm it isn't clipping. Then use loudnorm in lesson 5 and notice how it differs from a simple volume boost.

Progress

Progress is local-only — sign in to sync across devices.
Spotted a bug or have feedback on this page?Report an Issue

Comments 0

🔔 Reply notifications (sign in)
Sign inPlease sign in to comment.

No comments yet — be the first.