decoder/opus: move comment to `output_gain` field

This commit is contained in:
Max Kellermann 2020-10-16 18:30:34 +02:00
parent c32a809d38
commit 78ee663660
1 changed files with 4 additions and 5 deletions

View File

@ -76,8 +76,9 @@ class MPDOpusDecoder final : public OggDecoder {
opus_int16 *output_buffer = nullptr; opus_int16 *output_buffer = nullptr;
/** /**
* The output gain from the Opus header. Initialized by * The output gain from the Opus header in dB that should be
* OnOggBeginning(). * applied unconditionally, but is often used specifically for
* ReplayGain. Initialized by OnOggBeginning().
*/ */
float output_gain; float output_gain;
@ -250,9 +251,7 @@ MPDOpusDecoder::HandleTags(const ogg_packet &packet)
rgi.Clear(); rgi.Clear();
/** /**
* Output gain is a Q7.8 fixed point number in dB that should be, * Add 5dB to compensate for the different
* applied unconditionally, but is often used specifically for
* ReplayGain. Add 5dB to compensate for the different
* reference levels between ReplayGain (89dB) and EBU R128 (-23 LUFS). * reference levels between ReplayGain (89dB) and EBU R128 (-23 LUFS).
*/ */
rgi.track.gain = output_gain + 5; rgi.track.gain = output_gain + 5;