diff options
author | Anton Khirnov <anton@khirnov.net> | 2013-05-07 09:20:32 +0400 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2022-03-15 15:42:40 +0300 |
commit | fa0c8a753e4851cfabf08fb558b0ca2616f27bbc (patch) | |
tree | ab4aab0d7eb6567ecec4c9ec1d4760ff1ccc555f /libavcodec/cook_parser.c | |
parent | cdde7fe41599ad554d8fba9e84f863a63f298e21 (diff) |
cook: 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 'libavcodec/cook_parser.c')
-rw-r--r-- | libavcodec/cook_parser.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/cook_parser.c b/libavcodec/cook_parser.c index a05ebf94b8..0d9473845e 100644 --- a/libavcodec/cook_parser.c +++ b/libavcodec/cook_parser.c @@ -41,8 +41,8 @@ static int cook_parse(AVCodecParserContext *s1, AVCodecContext *avctx, CookParseContext *s = s1->priv_data; if (!s->duration && - avctx->extradata && avctx->extradata_size >= 8 && avctx->channels) - s->duration = AV_RB16(avctx->extradata + 4) / avctx->channels; + avctx->extradata && avctx->extradata_size >= 8 && avctx->ch_layout.nb_channels) + s->duration = AV_RB16(avctx->extradata + 4) / avctx->ch_layout.nb_channels; s1->duration = s->duration; |