From 6a14bb11b68d2daca0ae1f3c522869f650be5a5c Mon Sep 17 00:00:00 2001 From: Liong Sauw Ming Date: Fri, 7 Aug 2015 09:22:32 +0000 Subject: Re #1843 (misc): Fixed wrong calculation of timestamp in L16 codec (should be multiplied by samples per frame instead of frame size). git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@5153 74dad513-b988-da41-8d7b-12977e46ad98 --- pjmedia/src/pjmedia-codec/l16.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pjmedia/src') diff --git a/pjmedia/src/pjmedia-codec/l16.c b/pjmedia/src/pjmedia-codec/l16.c index bd6cb0e0..e938dadd 100644 --- a/pjmedia/src/pjmedia-codec/l16.c +++ b/pjmedia/src/pjmedia-codec/l16.c @@ -591,7 +591,7 @@ static pj_status_t l16_parse( pjmedia_codec *codec, frames[count].type = PJMEDIA_FRAME_TYPE_AUDIO; frames[count].buf = pkt; frames[count].size = data->frame_size; - frames[count].timestamp.u64 = ts->u64 + (count * data->frame_size); + frames[count].timestamp.u64 = ts->u64 + (count * data->frame_size >> 1); pkt = ((char*)pkt) + data->frame_size; pkt_size -= data->frame_size; -- cgit v1.2.3