ffmpeg-normalize icon indicating copy to clipboard operation
ffmpeg-normalize copied to clipboard

Peak normalization with input_i 0 fails

Open manuel-arguelles opened this issue 6 months ago • 0 comments

It seems that the underlying ffmpeg in use doesn't support an input_i value of 0 for peak or rms modes, this is inconsistent with the documentation (min: -99, max: 0, default: -23), the output is:

   [loudnorm @ 0x3b2e1ec0] Value 0.000000 for parameter 'I' out of range [-70 - -5]
        Last message repeated 1 times
    [loudnorm @ 0x3b2e1ec0] Error setting option I to value 0.
    [Parsed_loudnorm_0 @ 0x3b2e1d80] Error applying options to the filter.
    [AVFilterGraph @ 0x3b28d200] Error initializing filter 'loudnorm' with args 'I=0:'
    Error reinitializing filters!
    Failed to inject frame into filter network: Numerical result out of range
    Error while processing the decoded data for stream #0:0
    Conversion failed!

The command was:

node_modules/ffmpeg-static/bin/linux/x64/ffmpeg -hide_banner -i "input.ogg" -af loudnorm=I=0: -ar 48k -y "output.ogg"

Invoked with:

  normalize({
    'input': 'input.ogg',
    'output': 'output.ogg',
    'loudness': {
      'normalization': 'peak',
      'target': {
        'input_i': 0,
      }
    },
    'verbose': false
  });

manuel-arguelles avatar Aug 05 '25 20:08 manuel-arguelles