[FFmpeg-cvslog] avcodec/mlpenc: add 2.1 layout support for truehd
Paul B Mahol
git at videolan.org
Sat Oct 21 00:31:39 EEST 2023
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Fri Oct 20 23:27:06 2023 +0200| [393d1ee541b143633bfba2ff0e821d734fd511c2] | committer: Paul B Mahol
avcodec/mlpenc: add 2.1 layout support for truehd
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=393d1ee541b143633bfba2ff0e821d734fd511c2
---
libavcodec/mlpenc.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/libavcodec/mlpenc.c b/libavcodec/mlpenc.c
index dcc61bd8c9..6b801605db 100644
--- a/libavcodec/mlpenc.c
+++ b/libavcodec/mlpenc.c
@@ -597,6 +597,7 @@ static av_cold int mlp_encode_init(AVCodecContext *avctx)
ctx->ch8_presentation_mod= 1;
ctx->thd_substream_info = 0x14;
break;
+ case AV_CH_LAYOUT_2POINT1:
case AV_CH_LAYOUT_SURROUND:
case AV_CH_LAYOUT_5POINT0:
case AV_CH_LAYOUT_5POINT1:
@@ -2323,10 +2324,11 @@ const FFCodec ff_truehd_encoder = {
.p.priv_class = &mlp_class,
.p.sample_fmts = (const enum AVSampleFormat[]) {AV_SAMPLE_FMT_S16P, AV_SAMPLE_FMT_S32P, AV_SAMPLE_FMT_NONE},
.p.supported_samplerates = (const int[]) {44100, 48000, 88200, 96000, 176400, 192000, 0},
- CODEC_OLD_CHANNEL_LAYOUTS(AV_CH_LAYOUT_MONO, AV_CH_LAYOUT_STEREO, AV_CH_LAYOUT_SURROUND, AV_CH_LAYOUT_5POINT0, AV_CH_LAYOUT_5POINT1)
+ CODEC_OLD_CHANNEL_LAYOUTS(AV_CH_LAYOUT_MONO, AV_CH_LAYOUT_STEREO, AV_CH_LAYOUT_2POINT1, AV_CH_LAYOUT_SURROUND, AV_CH_LAYOUT_5POINT0, AV_CH_LAYOUT_5POINT1)
.p.ch_layouts = (const AVChannelLayout[]) {
AV_CHANNEL_LAYOUT_MONO,
AV_CHANNEL_LAYOUT_STEREO,
+ AV_CHANNEL_LAYOUT_2POINT1,
AV_CHANNEL_LAYOUT_SURROUND,
AV_CHANNEL_LAYOUT_5POINT0,
AV_CHANNEL_LAYOUT_5POINT1,
More information about the ffmpeg-cvslog
mailing list