diff options
author | Anton Khirnov <anton@khirnov.net> | 2019-06-04 17:16:02 +0200 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2022-03-15 09:42:46 -0300 |
commit | 5636972c7acb5a485e1759db478ded70ee9d3832 (patch) | |
tree | 2cf11628c865339e88d00bc166c7a229ce931b6f /libavformat | |
parent | bfe86a761a969190ad93781ac5126e8c1742300f (diff) | |
download | ffmpeg-5636972c7acb5a485e1759db478ded70ee9d3832.tar.gz |
lavc: drop temporary compat wrappers for channel layout API change
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/demux.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/libavformat/demux.c b/libavformat/demux.c index 938af13831..e926bab690 100644 --- a/libavformat/demux.c +++ b/libavformat/demux.c @@ -1329,30 +1329,12 @@ static int read_frame_internal(AVFormatContext *s, AVPacket *pkt) } got_packet = 1; } else if (st->discard < AVDISCARD_ALL) { -#if FF_API_OLD_CHANNEL_LAYOUT -FF_DISABLE_DEPRECATION_WARNINGS - int orig_channels = sti->avctx->channels; - uint64_t orig_channel_layout = sti->avctx->channel_layout; -FF_ENABLE_DEPRECATION_WARNINGS -#endif if ((ret = parse_packet(s, pkt, pkt->stream_index, 0)) < 0) return ret; st->codecpar->sample_rate = sti->avctx->sample_rate; st->codecpar->bit_rate = sti->avctx->bit_rate; #if FF_API_OLD_CHANNEL_LAYOUT FF_DISABLE_DEPRECATION_WARNINGS - /* parser setting the old-style fields */ - if (sti->avctx->channels != orig_channels || - sti->avctx->channel_layout != orig_channel_layout) { - av_channel_layout_uninit(&sti->avctx->ch_layout); - if (sti->avctx->channel_layout) { - av_channel_layout_from_mask(&sti->avctx->ch_layout, sti->avctx->channel_layout); - } else { - sti->avctx->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC; - sti->avctx->ch_layout.nb_channels = sti->avctx->channels; - } - } - st->codecpar->channels = sti->avctx->ch_layout.nb_channels; st->codecpar->channel_layout = sti->avctx->ch_layout.order == AV_CHANNEL_ORDER_NATIVE ? sti->avctx->ch_layout.u.mask : 0; |