[FFmpeg-devel] [PATCH] AC3 volume options
Sun Dec 16 16:20:12 CET 2007
Michael Niedermayer wrote:
> On Sat, Dec 15, 2007 at 08:52:41PM -0500, Justin Ruggles wrote:
>> AC3, E-AC3, DTS, TrueHD all have dynamic range compression and dialog
>> normalization capability. Right now the AC3 decoder is the only one which
>> uses them, and it applies them by default.
>> This patch disables them by default, but adds the options to allow the user
>> to activate them if wanted.
>> The dialog normalization option is used for both encoding and decoding.
>> For the decoder, it just turns it on or off. For the encoder, the value is
>> used in the output stream.
> 1. decoders should export the dynamic range & dialog norm
> 2. encoders should use the values form 1. and of course end with the same
> -> this also means externally vissible values must be format independant
You're right. I should have re-read that section of the spec in detail.
It seems that the decoder should not apply the gain values, but only
transmit them to the "sound reproduction system".
> 3. the AC3 spec specifies clearly what are the mandatory defaults, why
> do you disregard that?
> 4. the spec says:
> "It is also permissible (again under listener control) for the decoder to use some
> fraction of the dynrng control value, and to use a different fraction of positive or negative values."
> why dont you do this and instead suggest a vastly inferrior switch on/off?!
Yes, it seems the default for dynamic range is to always apply it in the
decoder, but to have the option for the user to adjust the fraction of
what gain is applied. I will modify the patch accordingly.
I like Andreas' suggestion to make the dialog normalization value more
universal. I think a floating-point decibel value for the dialog level
would be appropriate.
I'll also split into 2 patches.
More information about the ffmpeg-devel