From a67b67944aa9e6e794934d15f9fd9a9cf7173e09 Mon Sep 17 00:00:00 2001 From: Vittorio Giovara <vittorio.giovara@gmail.com> Date: Fri, 24 Jul 2015 05:17:26 +0100 Subject: [PATCH] ac3enc_template: Use the correct context field For audio encoders, delay has no effect, use the appropriate one, initial_padding (see 2df0c32). --- libavcodec/ac3enc_template.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/ac3enc_template.c b/libavcodec/ac3enc_template.c index 79b4946b657..8febf858ef3 100644 --- a/libavcodec/ac3enc_template.c +++ b/libavcodec/ac3enc_template.c @@ -450,7 +450,7 @@ int AC3_NAME(encode_frame)(AVCodecContext *avctx, AVPacket *avpkt, ff_ac3_output_frame(s, avpkt->data); if (frame->pts != AV_NOPTS_VALUE) - avpkt->pts = frame->pts - ff_samples_to_time_base(avctx, avctx->delay); + avpkt->pts = frame->pts - ff_samples_to_time_base(avctx, avctx->initial_padding); *got_packet_ptr = 1; return 0; -- GitLab