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.)
This commit is contained in:
wm4 2013-05-13 23:54:27 +02:00
parent 8df712781c
commit 4931085a1b
1 changed files with 3 additions and 2 deletions

View File

@ -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
};