Opened 3 months ago

Last modified 6 weeks ago

#11093 new defect

Claimed unintentional channel layout overwritten resulting no sound

Reported by: solomoncyj Owned by:
Priority: normal Component: avfilter
Version: 6.1.1 Keywords: channelmap channel_layout
Cc: solomoncyj, MasterQuestionable Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description (last modified by solomoncyj)

Summary of the bug:
when i was encoding a dts 5.1 ch audio that had the layout of C L R Ls Rs LFE , file using ffmpeg via libopus , i found that the resulting file did not play in vlc, due to the channel layout being rewritten to L R C Lb Rb LFE. however if downmixed to stereo, there would be sound. FFmpeg should retain the channel layout, or copy the data in the channel to the correct one in the output file

How to reproduce:

% ffmpeg -i out.dts -c:a libopus -b:a 160k -af "channelmap=channel_layout=5.1" out.opus
ffmpeg version 6.1.1
built on dnf rpm fusion

Patches should be submitted to the ffmpeg-devel mailing list and not this bug tracker.

Attachments (1)

ffmpeg-20240707-164835.log (13.2 KB ) - added by solomoncyj 3 months ago.
logs

Download all attachments as: .zip

Change History (9)

by solomoncyj, 3 months ago

Attachment: ffmpeg-20240707-164835.log added

logs

comment:1 by solomoncyj, 3 months ago

Description: modified (diff)

comment:2 by solomoncyj, 3 months ago

Component: undeterminedffmpeg
Version: unspecified6.1.1

comment:3 by solomoncyj, 2 months ago

Priority: normalimportant
Summary: ffmpeg overwrting channel layout, resluting in no sound in vlcffmpeg and libopusoverwrting channel layout, resluting in no sound in vlc

comment:4 by solomoncyj, 6 weeks ago

errors were produce by the library (presumably) when i did not remap the channels

`
[libopus @ 0x561fbbfb0740] Invalid channel layout 5.1(side) for specified mapping family -1.
[aost#0:0/libopus @ 0x561fbbfb0480] Error while opening encoder - maybe incorrect parameters such as bit_rate, rate, width or height.
Error while filtering: Invalid argument
[out#0/opus @ 0x561fbbfad6c0] Nothing was written into output file, because at least one of its streams received no packets.
`

comment:5 by MasterQuestionable, 6 weeks ago

Cc: MasterQuestionable added
Component: ffmpegavfilter
Keywords: libopus removed
Priority: importantnormal
Summary: ffmpeg and libopusoverwrting channel layout, resluting in no sound in vlcClaimed unintentional channel layout overwritten resulting no sound

͏    `-af "channelmap=channel_layout=5.1"`..?
͏    Supposedly you instructed it?
͏    "channel layout being rewritten"

͏    See also: https://ffmpeg.org/ffmpeg-filters.html#channelmap
͏    And I guess irrelevant of Opus.

comment:6 by MasterQuestionable, 6 weeks ago

Keywords: channelmap added

comment:7 by solomoncyj, 6 weeks ago

well, it did not rewrite it correctly, as it should have mapped channel L -> L for example, how ever it mapped L -> C

Version 0, edited 6 weeks ago by solomoncyj (next)

comment:8 by MasterQuestionable, 6 weeks ago

͏    Make sure you specify the filter correctly, as intended.
͏    I scarcely use anything other than Mono/Stereo...

Note: See TracTickets for help on using tickets.