#11503(avcodec:new): AC-3 downmix levels defaulting to 1.414 with recent decoder changes
#11503: AC-3 downmix levels defaulting to 1.414 with recent decoder changes -------------------------------------+------------------------------------- Reporter: Wallboy | Type: defect Status: new | Priority: normal Component: avcodec | Version: git- Keywords: ac3 | master resampling downmix | Blocked By: Blocking: | Reproduced by developer: 0 Analyzed by developer: 0 | -------------------------------------+------------------------------------- **Summary of the bug:** With the recent commits to AC-3 decoder, I've noticed the default mixing levels (when no metadata present) have changed from 0.707 to 1.414 for both clev and slev, respectively. The ATSC A/52 spec does have these 1.414 values listed in the Alternate Bit Stream Syntax, but only for the center channel. **How to reproduce:** Run a command similar to the following on the latest master branch with a 5.1 channel AC-3 file (here using AAC codec so we get fltp sample format, so the rematrixing code doesn't normalize the mixing levels): {{{ ffmpeg -hide_banner -loglevel debug -i someac3file -vn -c:a aac -frames:a 1 -ac 2 -f null /dev/null }}} Relevant debug output: {{{ [auto_aresample_0 @ 000001c6d9787100] Mix levels: center 1.414214 - surround 1.414214 - lfe 0.000000. [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] Using fltp internally between filters [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] Matrix coefficients: [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] FL: FL:1.000000 FR:0.000000 FC:1.414214 LFE:0.000000 SL:1.414214 SR:0.000000 [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] FR: FL:0.000000 FR:1.000000 FC:1.414214 LFE:0.000000 SL:0.000000 SR:1.414214 }}} Run again on a release version of ffmpeg such as 7.1: {{{ [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] Matrix coefficients: [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] FL: FL:1.000000 FR:0.000000 FC:0.707107 LFE:0.000000 SL:0.707107 SR:0.000000 [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] FR: FL:0.000000 FR:1.000000 FC:0.707107 LFE:0.000000 SL:0.000000 SR:0.707107 }}} which I believe these are the expected defaults if the metadata doesn't explicitly specify otherwise. If this change was intentional, feel free to close this ticket. -- Ticket URL: <https://trac.ffmpeg.org/ticket/11503> FFmpeg <https://ffmpeg.org> FFmpeg issue tracker
#11503: AC-3 downmix levels defaulting to 1.414 with recent decoder changes -------------------------------------+------------------------------------- Reporter: Wallboy | Owner: (none) Type: defect | Status: new Priority: normal | Component: avcodec Version: git-master | Resolution: Keywords: ac3 | Blocked By: resampling downmix | Blocking: | Reproduced by developer: 0 Analyzed by developer: 0 | -------------------------------------+------------------------------------- Comment (by Balling): There is also this https://patchwork.ffmpeg.org/project/ffmpeg/patch/20250111141330.543-1-jamri... For center channel -- Ticket URL: <https://trac.ffmpeg.org/ticket/11503#comment:1> FFmpeg <https://ffmpeg.org> FFmpeg issue tracker
#11503: AC-3 downmix levels defaulting to 1.414 with recent decoder changes -------------------------------------+------------------------------------- Reporter: Wallboy | Owner: (none) Type: defect | Status: new Priority: normal | Component: avcodec Version: git-master | Resolution: Keywords: ac3 | Blocked By: resampling downmix | Blocking: | Reproduced by developer: 0 Analyzed by developer: 0 | -------------------------------------+------------------------------------- Description changed by Wallboy: Old description:
**Summary of the bug:**
With the recent commits to AC-3 decoder, I've noticed the default mixing levels (when no metadata present) have changed from 0.707 to 1.414 for both clev and slev, respectively.
The ATSC A/52 spec does have these 1.414 values listed in the Alternate Bit Stream Syntax, but only for the center channel.
**How to reproduce:**
Run a command similar to the following on the latest master branch with a 5.1 channel AC-3 file (here using AAC codec so we get fltp sample format, so the rematrixing code doesn't normalize the mixing levels):
{{{ ffmpeg -hide_banner -loglevel debug -i someac3file -vn -c:a aac -frames:a 1 -ac 2 -f null /dev/null }}}
Relevant debug output:
{{{ [auto_aresample_0 @ 000001c6d9787100] Mix levels: center 1.414214 - surround 1.414214 - lfe 0.000000. [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] Using fltp internally between filters [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] Matrix coefficients: [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] FL: FL:1.000000 FR:0.000000 FC:1.414214 LFE:0.000000 SL:1.414214 SR:0.000000 [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] FR: FL:0.000000 FR:1.000000 FC:1.414214 LFE:0.000000 SL:0.000000 SR:1.414214 }}}
Run again on a release version of ffmpeg such as 7.1:
{{{ [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] Matrix coefficients: [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] FL: FL:1.000000 FR:0.000000 FC:0.707107 LFE:0.000000 SL:0.707107 SR:0.000000 [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] FR: FL:0.000000 FR:1.000000 FC:0.707107 LFE:0.000000 SL:0.000000 SR:0.707107 }}}
which I believe these are the expected defaults if the metadata doesn't explicitly specify otherwise.
If this change was intentional, feel free to close this ticket.
New description: **Summary of the bug:** With the recent commits to AC-3 decoder, I've noticed the default mixing levels (when no metadata present) have changed from 0.707 to 1.414 for both clev and slev, respectively. The ATSC A/52 spec does have these 1.414 values listed in the Alternate Bit Stream Syntax, but only for the center channel. **How to reproduce:** Run a command similar to the following on the latest master branch with a 5.1 channel AC-3 file (here using AAC codec so we get fltp sample format, so the rematrixing code doesn't normalize the mixing levels): {{{ ffmpeg -hide_banner -loglevel debug -i someac3file -vn -c:a aac -frames:a 1 -ac 2 -f null /dev/null }}} Relevant debug output: {{{ [auto_aresample_0 @ 000001c6d9787100] Mix levels: center 1.414214 - surround 1.414214 - lfe 0.000000. [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] Using fltp internally between filters [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] Matrix coefficients: [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] FL: FL:1.000000 FR:0.000000 FC:1.414214 LFE:0.000000 SL:1.414214 SR:0.000000 [auto_aresample_0 @ 000001c6d9787100] [SWR @ 000001c6d9787fc0] FR: FL:0.000000 FR:1.000000 FC:1.414214 LFE:0.000000 SL:0.000000 SR:1.414214 }}} Run again on a release version of ffmpeg such as 7.1: {{{ [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] Matrix coefficients: [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] FL: FL:1.000000 FR:0.000000 FC:0.707107 LFE:0.000000 SL:0.707107 SR:0.000000 [auto_aresample_0 @ 00000228732b7440] [SWR @ 00000228734caf80] FR: FL:0.000000 FR:1.000000 FC:0.707107 LFE:0.000000 SL:0.000000 SR:0.707107 }}} which I believe these are the expected defaults if the metadata doesn't explicitly specify otherwise. If this change was intentional, feel free to close this ticket. ---- **UPDATE:** Furthermore, if you manually specify `-clev` and `-slev` values, they are ignored in the latest git master: {{{ [auto_aresample_0 @ 0000026f4df79680] [debug] Setting 'slev' to value '0.707' [auto_aresample_0 @ 0000026f4df79680] [debug] Setting 'clev' to value '0.707' ... [auto_aresample_0 @ 0000026f4df79680] [verbose] Mix levels: center 1.414214 - surround 1.414214 - lfe 0.000000. [auto_aresample_0 @ 0000026f4df79680] [SWR @ 0000026f4e03c900] [debug] Using fltp internally between filters [auto_aresample_0 @ 0000026f4df79680] [SWR @ 0000026f4e03c900] [debug] Matrix coefficients: [auto_aresample_0 @ 0000026f4df79680] [SWR @ 0000026f4e03c900] [debug] FL: FL:1.000000 FR:0.000000 FC:1.414214 LFE:0.000000 SL:1.414214 SR:0.000000 [auto_aresample_0 @ 0000026f4df79680] [SWR @ 0000026f4e03c900] [debug] FR: FL:0.000000 FR:1.000000 FC:1.414214 LFE:0.000000 SL:0.000000 SR:1.414214 }}} Probably related. -- -- Ticket URL: <https://trac.ffmpeg.org/ticket/11503#comment:2> FFmpeg <https://ffmpeg.org> FFmpeg issue tracker
#11503: AC-3 downmix levels defaulting to 1.414 with recent decoder changes -------------------------------------+------------------------------------- Reporter: Wallboy | Owner: (none) Type: defect | Status: new Priority: normal | Component: avcodec Version: git-master | Resolution: Keywords: ac3 | Blocked By: resampling downmix | Blocking: | Reproduced by developer: 0 Analyzed by developer: 0 | -------------------------------------+------------------------------------- Comment (by Balling): I will just point out that before another value was being ignored "Value 3 is used to signal "Dolby Pro Logic II" by some encoders." https://github.com/FFmpeg/FFmpeg/commit/9d16c64134b1731f5aa98f9a31afa297b119... Was not even set https://github.com/FFmpeg/FFmpeg/commit/15b16d58df7d2372c6b7535633556e955ab9... -- Ticket URL: <https://trac.ffmpeg.org/ticket/11503#comment:3> FFmpeg <https://ffmpeg.org> FFmpeg issue tracker
#11503: AC-3 downmix levels defaulting to 1.414 with recent decoder changes -------------------------------------+------------------------------------- Reporter: Wallboy | Owner: (none) Type: defect | Status: new Priority: normal | Component: avcodec Version: git-master | Resolution: Keywords: ac3 | Blocked By: resampling downmix | Blocking: | Reproduced by developer: 0 Analyzed by developer: 0 | -------------------------------------+------------------------------------- Comment (by Wallboy): ''"Have you checked patch above?"'' yes, it's not relevant code for rematrixing 5.1 -> 2.0. ''"when no metadata present" would not that metadata always be present when encoded with Dolby Media Encoder?'' The file I've been testing with is an **E-AC-3** file. I should have made that clearer, sorry. In E-AC-3 there is a bit (mixmdate) that specifies if mixing levels/downmix mode is present. In my test file, there wasn't. -- Ticket URL: <https://trac.ffmpeg.org/ticket/11503#comment:4> FFmpeg <https://ffmpeg.org> FFmpeg issue tracker
participants (1)
-
FFmpeg