(FFmpeg) How to Add Color Normalization to a Video?

Normalization is a color correction filter that standardizes the RGB values in each frame of a video. With the use of histogram and contrast stretching, FFmpeg can quickly fix issues like rapid brightness changes and flickering. Below is an example of normalization at the highest strength:

  $ ffmpeg -i input.mp4 -vf "normalize=strength=1" output.mp4   

Tip: If this filter is applied to an MP4, you may need to add a pixel format, -pix_fmt yuv420p, for the previewer to work on macOS.

normalize
	Indicates the normalization filter name

strength
	Indicates the strength of the normalization, large the value higher the strength (1.0 to 0.0 with default 1.0)

smoothing
	Indicates setting a temporal smoothing based on the previous frame (1 or 0 with a default 0 - no smoothing)

Love FFmpeg? Grab a copy of FFmpeg For Beginners on Kindle or Paperback to learn over 120 ways to master FFmpeg!

buy now on amazon

Related Posts