Log in

View Full Version : Is it possible to detect if a 2-channel audio file has surround information in it?


numaios
10th December 2017, 05:30
Hello.

I don't know if this will be a dumb question, but I've been doing search and couldn't find it.

Sometimes when you encode a movie, which comes with AC-3 5.1, you can downmix to stereo or DPL or DPL II and encode to MP3 or AAC.

But, what if you can't remember if you chose stereo or DPL? Is it possible to analyze the file and tell? Is there any app? Mediainfo won't show this info, since it will only tell the number of channels the file has, but it won't tell if it carries surround info matrixed.

Besides, I've seen that Handbrake sometimes tells the audio input is an "AC-3 2.0 Surround". How can it know?

Thank you very much,

tebasuna51
10th December 2017, 10:17
There are a flag in AC3 header than show if is DPL or not.
Other formats (mp3, aac) can't remember that info.

But when downmix a 5.1 to 2.0 dpl you must set this flag at encode time.
See the attached image when encode using BeHappy.
Thats add the parameter -dsur_mode on
to ffmpeg command line encode.

MediaInfo in advanced mode show:

dsurmod : Dolby Surround encoded

Or eac3to:

AC3 Surround, 2.0 channels, 0:00:20, 256kbps, 48kHz

That flag must activate the DPL decoder mode in receivers with DPL support.
With other formats (mp3, aac, ...) you must activate the DPL decoder mode manually.

numaios
11th December 2017, 18:47
Thank you very much, Tebasuna51. Do you know if this flag is preserved when the AC-3 is muxed into a mkv file?

tebasuna51
11th December 2017, 19:05
Of course, it is part of each AC3 frame.

numaios
11th December 2017, 19:25
:thanks: