diff options
author | Anton Khirnov <anton@khirnov.net> | 2019-05-13 11:11:26 +0200 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2022-03-15 09:42:30 -0300 |
commit | 820d73cc0e8368f66849e3d5006844dbdb1f2775 (patch) | |
tree | 1d8cd2f18d06f55849469d0a833c2d0b9e5fb579 /libavformat/astenc.c | |
parent | 521cca1333852cc46682cc78d40ae51d10bc14a5 (diff) |
ast: convert to new channel layout API
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavformat/astenc.c')
-rw-r--r-- | libavformat/astenc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/astenc.c b/libavformat/astenc.c index a5792e0b07..b29cfc4aaf 100644 --- a/libavformat/astenc.c +++ b/libavformat/astenc.c @@ -84,7 +84,7 @@ static int ast_write_header(AVFormatContext *s) avio_wb32(pb, 0); /* File size minus header */ avio_wb16(pb, codec_tag); avio_wb16(pb, 16); /* Bit depth */ - avio_wb16(pb, par->channels); + avio_wb16(pb, par->ch_layout.nb_channels); avio_wb16(pb, 0); /* Loop flag */ avio_wb32(pb, par->sample_rate); @@ -109,7 +109,7 @@ static int ast_write_packet(AVFormatContext *s, AVPacket *pkt) AVIOContext *pb = s->pb; ASTMuxContext *ast = s->priv_data; AVCodecParameters *par = s->streams[0]->codecpar; - int size = pkt->size / par->channels; + int size = pkt->size / par->ch_layout.nb_channels; if (s->streams[0]->nb_frames == 0) ast->fbs = size; |