From b2302b9de9162ed958a8c8c415b84f2c85784e4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nathana=C3=ABl=20Semhoun?= Date: Fri, 18 Jun 2021 00:28:39 +0200 Subject: [PATCH] Fix G729 packet duration Without this correction, timestamp is not incremented in case of transcoding (cherry picked from commit c76b0b7ef6f2fa7a20c2d7d6b89876fb42dbd143) Change-Id: I64bba46b276cb722f1caede68eb21fecd60ca955 --- lib/codeclib.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/codeclib.c b/lib/codeclib.c index 73a132504..8ab648df2 100644 --- a/lib/codeclib.c +++ b/lib/codeclib.c @@ -2219,6 +2219,7 @@ static int bcg729_encoder_input(encoder_t *enc, AVFrame **frame) { enc->avpkt.size = len; enc->avpkt.pts = (*frame)->pts; + enc->avpkt.duration = len * 8; // Duration is used by encoder_input_data for pts calculation return 0; }