avutil/channel_layout: add a 3.1.2 channel layout

Signed-off-by: James Almer <jamrial@gmail.com>
pull/390/head
James Almer 1 year ago
parent e9397ae054
commit 35b06853d1
  1. 2
      doc/utils.texi
  2. 1
      libavutil/channel_layout.c
  3. 2
      libavutil/channel_layout.h
  4. 1
      tests/ref/fate/channel_layout

@ -695,6 +695,8 @@ FL+FR+FC+LFE+SL+SR
FL+FR+FC+BC+SL+SR FL+FR+FC+BC+SL+SR
@item 6.0(front) @item 6.0(front)
FL+FR+FLC+FRC+SL+SR FL+FR+FLC+FRC+SL+SR
@item 3.1.2
FL+FR+FC+LFE+TFL+TFR
@item hexagonal @item hexagonal
FL+FR+FC+BL+BR+BC FL+FR+FC+BL+BR+BC
@item 6.1 @item 6.1

@ -191,6 +191,7 @@ static const struct channel_layout_name channel_layout_map[] = {
{ "5.1(side)", AV_CHANNEL_LAYOUT_5POINT1 }, { "5.1(side)", AV_CHANNEL_LAYOUT_5POINT1 },
{ "6.0", AV_CHANNEL_LAYOUT_6POINT0 }, { "6.0", AV_CHANNEL_LAYOUT_6POINT0 },
{ "6.0(front)", AV_CHANNEL_LAYOUT_6POINT0_FRONT }, { "6.0(front)", AV_CHANNEL_LAYOUT_6POINT0_FRONT },
{ "3.1.2", AV_CHANNEL_LAYOUT_3POINT1POINT2 },
{ "hexagonal", AV_CHANNEL_LAYOUT_HEXAGONAL }, { "hexagonal", AV_CHANNEL_LAYOUT_HEXAGONAL },
{ "6.1", AV_CHANNEL_LAYOUT_6POINT1 }, { "6.1", AV_CHANNEL_LAYOUT_6POINT1 },
{ "6.1(back)", AV_CHANNEL_LAYOUT_6POINT1_BACK }, { "6.1(back)", AV_CHANNEL_LAYOUT_6POINT1_BACK },

@ -224,6 +224,7 @@ enum AVChannelOrder {
#define AV_CH_LAYOUT_6POINT0 (AV_CH_LAYOUT_5POINT0|AV_CH_BACK_CENTER) #define AV_CH_LAYOUT_6POINT0 (AV_CH_LAYOUT_5POINT0|AV_CH_BACK_CENTER)
#define AV_CH_LAYOUT_6POINT0_FRONT (AV_CH_LAYOUT_2_2|AV_CH_FRONT_LEFT_OF_CENTER|AV_CH_FRONT_RIGHT_OF_CENTER) #define AV_CH_LAYOUT_6POINT0_FRONT (AV_CH_LAYOUT_2_2|AV_CH_FRONT_LEFT_OF_CENTER|AV_CH_FRONT_RIGHT_OF_CENTER)
#define AV_CH_LAYOUT_HEXAGONAL (AV_CH_LAYOUT_5POINT0_BACK|AV_CH_BACK_CENTER) #define AV_CH_LAYOUT_HEXAGONAL (AV_CH_LAYOUT_5POINT0_BACK|AV_CH_BACK_CENTER)
#define AV_CH_LAYOUT_3POINT1POINT2 (AV_CH_LAYOUT_3POINT1|AV_CH_TOP_FRONT_LEFT|AV_CH_TOP_FRONT_RIGHT)
#define AV_CH_LAYOUT_6POINT1 (AV_CH_LAYOUT_5POINT1|AV_CH_BACK_CENTER) #define AV_CH_LAYOUT_6POINT1 (AV_CH_LAYOUT_5POINT1|AV_CH_BACK_CENTER)
#define AV_CH_LAYOUT_6POINT1_BACK (AV_CH_LAYOUT_5POINT1_BACK|AV_CH_BACK_CENTER) #define AV_CH_LAYOUT_6POINT1_BACK (AV_CH_LAYOUT_5POINT1_BACK|AV_CH_BACK_CENTER)
#define AV_CH_LAYOUT_6POINT1_FRONT (AV_CH_LAYOUT_6POINT0_FRONT|AV_CH_LOW_FREQUENCY) #define AV_CH_LAYOUT_6POINT1_FRONT (AV_CH_LAYOUT_6POINT0_FRONT|AV_CH_LOW_FREQUENCY)
@ -394,6 +395,7 @@ typedef struct AVChannelLayout {
#define AV_CHANNEL_LAYOUT_5POINT1_BACK AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_5POINT1_BACK) #define AV_CHANNEL_LAYOUT_5POINT1_BACK AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_5POINT1_BACK)
#define AV_CHANNEL_LAYOUT_6POINT0 AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_6POINT0) #define AV_CHANNEL_LAYOUT_6POINT0 AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_6POINT0)
#define AV_CHANNEL_LAYOUT_6POINT0_FRONT AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_6POINT0_FRONT) #define AV_CHANNEL_LAYOUT_6POINT0_FRONT AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_6POINT0_FRONT)
#define AV_CHANNEL_LAYOUT_3POINT1POINT2 AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_3POINT1POINT2)
#define AV_CHANNEL_LAYOUT_HEXAGONAL AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_HEXAGONAL) #define AV_CHANNEL_LAYOUT_HEXAGONAL AV_CHANNEL_LAYOUT_MASK(6, AV_CH_LAYOUT_HEXAGONAL)
#define AV_CHANNEL_LAYOUT_6POINT1 AV_CHANNEL_LAYOUT_MASK(7, AV_CH_LAYOUT_6POINT1) #define AV_CHANNEL_LAYOUT_6POINT1 AV_CHANNEL_LAYOUT_MASK(7, AV_CH_LAYOUT_6POINT1)
#define AV_CHANNEL_LAYOUT_6POINT1_BACK AV_CHANNEL_LAYOUT_MASK(7, AV_CH_LAYOUT_6POINT1_BACK) #define AV_CHANNEL_LAYOUT_6POINT1_BACK AV_CHANNEL_LAYOUT_MASK(7, AV_CH_LAYOUT_6POINT1_BACK)

@ -15,6 +15,7 @@ quad(side) FL+FR+SL+SR
5.1(side) FL+FR+FC+LFE+SL+SR 5.1(side) FL+FR+FC+LFE+SL+SR
6.0 FL+FR+FC+BC+SL+SR 6.0 FL+FR+FC+BC+SL+SR
6.0(front) FL+FR+FLC+FRC+SL+SR 6.0(front) FL+FR+FLC+FRC+SL+SR
3.1.2 FL+FR+FC+LFE+TFL+TFR
hexagonal FL+FR+FC+BL+BR+BC hexagonal FL+FR+FC+BL+BR+BC
6.1 FL+FR+FC+LFE+BC+SL+SR 6.1 FL+FR+FC+LFE+BC+SL+SR
6.1(back) FL+FR+FC+LFE+BL+BR+BC 6.1(back) FL+FR+FC+LFE+BL+BR+BC

Loading…
Cancel
Save