diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2017-03-31 17:14:42 +0200 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2022-03-15 09:42:34 -0300 |
commit | b828c3954e61145957b60653a1e0957072221923 (patch) | |
tree | 5795738b51ae455a150eed2520549a5e2a6b6546 /libavformat/isom.c | |
parent | 3654db79f4b912c1a4c3d16700c341628e40de3c (diff) | |
download | ffmpeg-b828c3954e61145957b60653a1e0957072221923.tar.gz |
mov: convert to new channel layout API
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavformat/isom.c')
-rw-r--r-- | libavformat/isom.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libavformat/isom.c b/libavformat/isom.c index 015c82e1bb..e6569dfb68 100644 --- a/libavformat/isom.c +++ b/libavformat/isom.c @@ -360,7 +360,8 @@ int ff_mp4_read_dec_config_descr(AVFormatContext *fc, AVStream *st, AVIOContext st->codecpar->extradata_size, 1, fc); if (ret < 0) return ret; - st->codecpar->channels = cfg.channels; + st->codecpar->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC; + st->codecpar->ch_layout.nb_channels = cfg.channels; if (cfg.object_type == 29 && cfg.sampling_index < 3) // old mp3on4 st->codecpar->sample_rate = ff_mpa_freq_tab[cfg.sampling_index]; else if (cfg.ext_sample_rate) @@ -368,7 +369,7 @@ int ff_mp4_read_dec_config_descr(AVFormatContext *fc, AVStream *st, AVIOContext else st->codecpar->sample_rate = cfg.sample_rate; av_log(fc, AV_LOG_TRACE, "mp4a config channels %d obj %d ext obj %d " - "sample rate %d ext sample rate %d\n", st->codecpar->channels, + "sample rate %d ext sample rate %d\n", cfg.channels, cfg.object_type, cfg.ext_object_type, cfg.sample_rate, cfg.ext_sample_rate); if (!(st->codecpar->codec_id = ff_codec_get_id(mp4_audio_types, |