Inconsistent mapping of 5.1 FLAC/PCM on 7.1 system
#1
Equipment: Acer Aspire Revo 1600
Speaker configuration: 7.1
Audio/Video connected through: HDMI
XBMC version: Live / Dharma Beta 2
NVidia version: 256.53

Summary of issue:
When my speaker configuration is set to 5.1, channel mapping of FLAC sources within XBMC is 100% correct. When I change to 7.1, channel mapping becomes seemingly random. I see errors in the log message saying that "FFmpeg did not report a channel layout, trying to guess." It appears as if it truly is guessing, as every time I stop/start the video, the mappings are applied differently.

Since there appears to be a way for the system to figure out the logic with a 5.1 speaker configuration, it appears to be possible, but perhaps something is coded incorrectly in the 7.1 setup? I have updated my asound.conf file with the proper mapping in the past (from this thread), but maybe additional mapping is needed to get 7.1 working consistently as well as 5.1?

My log snippets are below. Full log available here.

Any help is much appreciated!

Media Info of file in question:
Code:
Complete name                    : P:\Videos\Movies\CrashPlan Movies-VM\Blu-ray Rips\The Devil Wears Prada (2006)\The Devil Wears Prada.bluray.mkv
Format                           : Matroska
File size                        : 10.3 GiB
Duration                         : 1h 49mn
Overall bit rate                 : 13.5 Mbps
Movie name                       : The Devil Wears Prada
Encoded date                     : UTC 2010-10-04 01:12:51
Writing application              : mkvmerge v4.3.0 ('Escape from the Island') built on Sep  5 2010 10:30:51
Writing library                  : libebml v1.0.0 + libmatroska v1.0.0

Video
ID                               : 1
Format                           : AVC
Format/Info                      : Advanced Video Codec
Format profile                   : [email protected]
Format settings, CABAC           : Yes
Format settings, ReFrames        : 3 frames
Muxing mode                      : Container [email protected]
Codec ID                         : V_MPEG4/ISO/AVC
Duration                         : 1h 49mn
Bit rate mode                    : Variable
Maximum bit rate                 : 25.0 Mbps
Width                            : 1 920 pixels
Height                           : 1 080 pixels
Display aspect ratio             : 16:9
Frame rate                       : 23.976 fps
Color space                      : YUV
Chroma subsampling               : 4:2:0
Bit depth                        : 8 bits
Scan type                        : Progressive
Writing library                  : x264 core 105 r1732 2b04482
Encoding settings                : cabac=1 / ref=3 / deblock=1:0:0 / analyse=0x3:0x133 / me=umh / subme=7 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=1 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=12 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / constrained_intra=0 / bframes=3 / b_pyramid=0 / b_adapt=1 / b_bias=0 / direct=1 / weightb=1 / open_gop=0 / weightp=2 / keyint=240 / keyint_min=24 / scenecut=40 / intra_refresh=0 / rc_lookahead=40 / rc=crf / mbtree=1 / crf=18.0 / qcomp=0.60 / qpmin=10 / qpmax=51 / qpstep=4 / vbv_maxrate=25000 / vbv_bufsize=25000 / crf_max=0.0 / ip_ratio=1.40 / aq=1:1.00 / nal_hrd=vbr

Audio
ID                               : 2
Format                           : FLAC
Format/Info                      : Free Lossless Audio Codec
Codec ID                         : A_FLAC
Duration                         : 1h 49mn
Bit rate mode                    : Variable
Channel(s)                       : 6 channels
Sampling rate                    : 48.0 KHz
Bit depth                        : 24 bits
Title                            : DTS HD-MA 5.1
Writing library                  : libFLAC 1.2.1 (UTC 2007-09-17)
Language                         : English

5.1 to 7.1 mapping working incorrectly:


Quote:23:52:41 T:2728991600 M:581320704 INFO: CDVDAudioCodecFFmpeg::GetChannelMap - FFmpeg did not report a channel layout, trying to guess
23:52:41 T:2728991600 M:581066752 NOTICE: Creating audio device with codec id: 86031, channels: 6, sample rate: 48000, no pass-through
23:52:41 T:2728991600 M:581066752 INFO: CPCMRemap: Configured speaker layout: 7.1
23:52:41 T:2728991600 M:580939776 INFO: CPCMRemap: I channel map: FL,FR,CE,LFE,SL,SR
23:52:41 T:2728991600 M:580939776 INFO: CPCMRemap: O channel map: FL,FR,BL,BR,CE,LFE,SL,SR
23:52:41 T:2728991600 M:580939776 DEBUG: CPCMRemap: Downmix normalization is disabled
23:52:41 T:2728991600 M:580812800 DEBUG: CPCMRemap: FL = FL(1.000000*)
23:52:41 T:2728991600 M:580812800 DEBUG: CPCMRemap: FR = FR(1.000000*)
23:52:41 T:2728991600 M:580812800 DEBUG: CPCMRemap: BL =
23:52:41 T:2728991600 M:580685824 DEBUG: CPCMRemap: BR =
23:52:41 T:2728991600 M:580685824 DEBUG: CPCMRemap: CE = CE(1.000000*)
23:52:41 T:2728991600 M:580685824 DEBUG: CPCMRemap: LFE = LFE(1.000000*)
23:52:41 T:2728991600 M:580558848 DEBUG: CPCMRemap: SL = SL(1.000000*)
23:52:41 T:2728991600 M:580431872 DEBUG: CPCMRemap: SR = SR(1.000000*)
23:52:41 T:2728991600 M:580431872 DEBUG: CALSADirectSound::CALSADirectSound - Requested channels changed from 6 to 8

5.1 to 7.1 Mapping Working Correctly

Quote:23:59:04 T:2684353392 M:550670336 INFO: CDVDAudioCodecFFmpeg::GetChannelMap - FFmpeg did not report a channel layout, trying to guess
23:59:04 T:2684353392 M:550670336 NOTICE: Creating audio device with codec id: 86031, channels: 6, sample rate: 48000, no pass-through
23:59:04 T:2684353392 M:550670336 INFO: CPCMRemap: Configured speaker layout: 7.1
23:59:04 T:2684353392 M:550670336 INFO: CPCMRemap: I channel map: FL,FR,CE,LFE,SL,SR
23:59:04 T:2684353392 M:550670336 INFO: CPCMRemap: O channel map: FL,FR,BL,BR,CE,LFE,SL,SR
23:59:04 T:2684353392 M:550670336 DEBUG: CPCMRemap: Downmix normalization is disabled
23:59:04 T:2684353392 M:550670336 DEBUG: CPCMRemap: FL = FL(1.000000*)
23:59:04 T:2684353392 M:550670336 DEBUG: CPCMRemap: FR = FR(1.000000*)
23:59:04 T:2684353392 M:550670336 DEBUG: CPCMRemap: BL =
23:59:04 T:2684353392 M:550543360 DEBUG: CPCMRemap: BR =
23:59:04 T:2684353392 M:550543360 DEBUG: CPCMRemap: CE = CE(1.000000*)
23:59:04 T:2684353392 M:550543360 DEBUG: CPCMRemap: LFE = LFE(1.000000*)
23:59:04 T:2684353392 M:550543360 DEBUG: CPCMRemap: SL = SL(1.000000*)
23:59:04 T:2684353392 M:550543360 DEBUG: CPCMRemap: SR = SR(1.000000*)
23:59:04 T:2684353392 M:550543360 DEBUG: CALSADirectSound::CALSADirectSound - Requested channels changed from 6 to 8

Lastly, this is what it looks like when I reconfigure the system settings to a 5.1 setup, even though I do have 7.1. (it works as expected every time)

5.1 to 5.1 Mapping Working Correctly

Quote:00:26:36 T:2518657904 M:531628032 INFO: CDVDAudioCodecFFmpeg::GetChannelMap - FFmpeg did not report a channel layout, trying to guess
00:26:36 T:2518657904 M:531628032 NOTICE: Creating audio device with codec id: 86031, channels: 6, sample rate: 48000, no pass-through
00:26:36 T:2518657904 M:531628032 INFO: CPCMRemap: Configured speaker layout: 5.1
00:26:36 T:2518657904 M:531628032 INFO: CPCMRemap: I channel map: FL,FR,CE,LFE,SL,SR
00:26:36 T:2518657904 M:531628032 DEBUG: CPCMRemap: Forcing side channel map to back channels
00:26:36 T:2518657904 M:531628032 INFO: CPCMRemap: O channel map: FL,FR,BL,BR,CE,LFE
00:26:36 T:2518657904 M:531628032 DEBUG: CPCMRemap: Downmix normalization is disabled
00:26:36 T:2518657904 M:531468288 DEBUG: CPCMRemap: FL = FL(1.000000*)
00:26:36 T:2518657904 M:531468288 DEBUG: CPCMRemap: FR = FR(1.000000*)
00:26:36 T:2518657904 M:531468288 DEBUG: CPCMRemap: BL = BL(1.000000*)
00:26:36 T:2518657904 M:531468288 DEBUG: CPCMRemap: BR = BR(1.000000*)
00:26:36 T:2518657904 M:531468288 DEBUG: CPCMRemap: CE = CE(1.000000*)
00:26:36 T:2518657904 M:531341312 DEBUG: CPCMRemap: LFE = LFE(1.000000*)
------------------------------------------
Dharma Quick Setup Guide:
XBMC tips on the TechNazgul Blog
------------------------------------------
Reply
#2
Just a friendly bump here to see if anyone can confirm this behavior and/or if more information is needed to troubleshoot.

Thank you.
------------------------------------------
Dharma Quick Setup Guide:
XBMC tips on the TechNazgul Blog
------------------------------------------
Reply
#3
check this out http://forum.xbmc.org/showpost.php?p=619...stcount=16

-=Jason=-
Reply
#4
Thanks for the answer Jason. Regrettably, that has no effect. Something definitely is funky with the 7.1 mappings in Dharma. Almost every time I play the same file, the mappings change. The first time, center channel audio comes from the rear right speaker, the next time, from the front right speaker, etc. The messages in the logs above indicate that XBMC is guessing as well.

Quote:"FFmpeg did not report a channel layout, trying to guess"

With that said, if I change my audio setup to 5.1 in the XBMC system settings, it's correct every time, even though the log still says it's guessing at the mappings.

Does anyone know where in the XBMC code the 7.1 vs. 5.1 settings mappings are stored? Is this in a user configurable file or hard coded in source?

Thank you.
------------------------------------------
Dharma Quick Setup Guide:
XBMC tips on the TechNazgul Blog
------------------------------------------
Reply
#5
You are not alone...

I'm using an ASROCK ION 330HT-BD with Dharma RC2.
I'm having the EXACT same problem when using 7.1 channels.
The mapping is wrong!!!

Please let me know if you find an answer...
Reply
#6
This has probably been fixed in r35522.
Reply
#7
Thanks for replying bobo1on1. If r35522 did not make it into RC2, then maybe, but the problem still does exist in RC2. I updated the TRAC ticket with that info as well so that the devs following that ticket would be aware.

If I can provide more info to help, please let me know. It'd be great to get this one ironed out before Dharma goes final!
------------------------------------------
Dharma Quick Setup Guide:
XBMC tips on the TechNazgul Blog
------------------------------------------
Reply
#8
Must be a different issue then.
Reply

Logout Mark Read Team Forum Stats Members Help
Inconsistent mapping of 5.1 FLAC/PCM on 7.1 system0