diff options
author | wm4 <wm4@nowhere> | 2013-05-13 23:54:27 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2013-05-13 23:55:39 +0200 |
commit | 4931085a1ba0017dd848b8086c0d89e7abbe10d7 (patch) | |
tree | a3c2db412ae8f76d618f1edad6359ce3520ff477 /audio | |
parent | 8df712781cab68e490ecfdc055e20898dc371f5d (diff) | |
download | mpv-4931085a1ba0017dd848b8086c0d89e7abbe10d7.tar.bz2 mpv-4931085a1ba0017dd848b8086c0d89e7abbe10d7.tar.xz |
chmap: fix oddity due to ambiguous 6.1 ffmpeg channel layout
FFmpeg (as well as Libav) have two layouts called "6.1":
AV_CH_LAYOUT_6POINT1 and AV_CH_LAYOUT_6POINT1_BACK. We call them "6.1"
and "6.1(back)". Change the default layout for 7 channels as well to
return the same layout as av_get_default_channel_layout(). (Looks a bit
questionable, but for now it's better to follow FFmpeg.)
Diffstat (limited to 'audio')
-rw-r--r-- | audio/chmap.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/audio/chmap.c b/audio/chmap.c index 77bd998835..254d9b38da 100644 --- a/audio/chmap.c +++ b/audio/chmap.c @@ -75,7 +75,8 @@ static const char *std_layout_names[][2] = { {"6.0", "fl-fr-fc-bc-sl-sr"}, {"6.0(front)", "fl-fr-flc-frc-sl-sr"}, {"hexagonal", "fl-fr-fc-bl-br-bc"}, - {"6.1", "fl-fr-fc-lfe-bl-br-bc"}, + {"6.1", "fl-fr-fc-lfe-bc-sl-sr"}, + {"6.1(back)", "fl-fr-fc-lfe-bl-br-bc"}, // lavc calls this "6.1" too {"6.1(front)", "fl-fr-lfe-flc-frc-sl-sr"}, {"7.0", "fl-fr-fc-bl-br-sl-sr"}, {"7.0(front)", "fl-fr-fc-flc-frc-sl-sr"}, @@ -96,7 +97,7 @@ static const struct mp_chmap default_layouts[MP_NUM_CHANNELS + 1] = { MP_CHMAP4(FL, FR, FC, BC), // 4.0 MP_CHMAP5(FL, FR, FC, BL, BR), // 5.0 MP_CHMAP6(FL, FR, FC, LFE, BL, BR), // 5.1 - MP_CHMAP7(FL, FR, FC, LFE, BL, BR, BC), // 6.1 + MP_CHMAP7(FL, FR, FC, LFE, BC, SL, SR), // 6.1 MP_CHMAP8(FL, FR, FC, LFE, BL, BR, SL, SR), // 7.1 }; |