[
http://opencast.jira.com/browse/MH-6386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=31407#comment-31407
]
Stephen Marquard commented on MH-6386:
--------------------------------------
Testing on some local files from different CAs with widely varying audio levels
suggest that it's more useful to adjust the gain based on RMS level db rather
than peak level db (the latter is what sox does with the --norm option or gain
-n).
To normalize based on RMS level db:
sox audio.flac -n remix - stats
produces output like:
DC offset 0.000000
Min level -0.473055
Max level 0.442322
Pk lev dB -6.50
RMS lev dB -35.16
RMS Pk dB -18.24
RMS Tr dB -63.50
Crest factor 27.10
Flat factor 0.00
Pk count 2
Bit-depth 24/25
Num samples 132M
Length s 2999.230
Scale max 1.000000
Window s 0.050
We then estimate a gain change to adjust RMS lev dB to approx -30:
e.g. decrease:
sox audio.flac rmsnorm.flac remix - gain -21.2 stats
or increase with -l flag to prevent clipping:
sox audio.flac rmsnorm.flac remix - gain -l 5.16 stats
The above includes merging stereo channels to mono (remix -). Final "stats" is
optional to get the revised RMS db for info.
This does seem to be a 2-step process though (first run sox to get the RMS
level db, then calculate gain increase / decrease then run again to adjust).
> Add a workflow operation to normalize audio
> -------------------------------------------
>
> Key: MH-6386
> URL: http://opencast.jira.com/browse/MH-6386
> Project: Matterhorn Project
> Issue Type: Task
> Components: Architecture & Services
> Affects Versions: 1.2
> Reporter: Christopher Brooks
>
> Check if you can do this with ffmpeg or maybe with lame, then consider how to
> add it as a workflow operation.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
http://opencast.jira.com/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
_______________________________________________
Matterhorn mailing list
[email protected]
http://lists.opencastproject.org/mailman/listinfo/matterhorn
To unsubscribe please email
[email protected]
_______________________________________________