[Home]

Summary:ASTERISK-13188: [patch] Jitterbuffer stops accepting new frames until it is empty after maxjitterbuffer is exceeded.
Reporter:Matthew Nicholson (mnicholson)Labels:
Date Opened:2008-12-09 12:16:26.000-0600Date Closed:2009-02-10 12:19:52.000-0600
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/Jitterbuffer
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) bug14044-1.diff
Description:Once the jitterbuffer exceeds maxjitterbuffer it stops accepting new frames until the buffer is emptied.  This can cause large audio dropouts.

****** ADDITIONAL INFORMATION ******

Please test the attached patch and see if it fixes the issue.
Comments:By: Anton Vazir (vazir) 2009-01-24 03:55:17.000-0600

I confirm this behavior in 1.4.21.2

By: Matthew Nicholson (mnicholson) 2009-01-26 09:12:24.000-0600

vazir,

Can you test the attached patch and see if it fixes the issue?

By: Digium Subversion (svnbot) 2009-02-10 11:52:43.000-0600

Repository: asterisk
Revision: 174583

U   branches/1.4/main/jitterbuf.c

------------------------------------------------------------------------
r174583 | mnicholson | 2009-02-10 11:52:42 -0600 (Tue, 10 Feb 2009) | 18 lines

Improve behavior of jitterbuffer when maxjitterbuffer is set.

This change improves the way the jitterbuffer handles maxjitterbuffer and
dramatically reduces the number of frames dropped when maxjitterbuffer is
exceeded.  In the previous jitterbuffer, when maxjitterbuffer was exceeded, all
new frames were dropped until the jitterbuffer is empty.  This change modifies
the code to only drop frames until maxjitterbuffer is no longer exceeded.

Also, previously when maxjitterbuffer was exceeded, dropped frames were not
tracked causing stats for dropped frames to be incorrect, this change also
addresses that problem.

(closes issue ASTERISK-13188)
Patches:
     bug14044-1.diff uploaded by mnicholson (license 96)
Tested by: mnicholson
Review: http://reviewboard.digium.com/r/144/

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=174583

By: Digium Subversion (svnbot) 2009-02-10 12:16:31.000-0600

Repository: asterisk
Revision: 174584

_U  trunk/
U   trunk/main/jitterbuf.c

------------------------------------------------------------------------
r174584 | mnicholson | 2009-02-10 12:16:31 -0600 (Tue, 10 Feb 2009) | 25 lines

Merged revisions 174583 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
 r174583 | mnicholson | 2009-02-10 11:52:42 -0600 (Tue, 10 Feb 2009) | 18 lines
 
 Improve behavior of jitterbuffer when maxjitterbuffer is set.
 
 This change improves the way the jitterbuffer handles maxjitterbuffer and
 dramatically reduces the number of frames dropped when maxjitterbuffer is
 exceeded.  In the previous jitterbuffer, when maxjitterbuffer was exceeded, all
 new frames were dropped until the jitterbuffer is empty.  This change modifies
 the code to only drop frames until maxjitterbuffer is no longer exceeded.
 
 Also, previously when maxjitterbuffer was exceeded, dropped frames were not
 tracked causing stats for dropped frames to be incorrect, this change also
 addresses that problem.
 
 (closes issue ASTERISK-13188)
 Patches:
       bug14044-1.diff uploaded by mnicholson (license 96)
 Tested by: mnicholson
 Review: http://reviewboard.digium.com/r/144/
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=174584

By: Digium Subversion (svnbot) 2009-02-10 12:18:30.000-0600

Repository: asterisk
Revision: 174590

_U  branches/1.6.1/
U   branches/1.6.1/main/jitterbuf.c

------------------------------------------------------------------------
r174590 | mnicholson | 2009-02-10 12:18:30 -0600 (Tue, 10 Feb 2009) | 32 lines

Merged revisions 174584 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
 r174584 | mnicholson | 2009-02-10 12:16:31 -0600 (Tue, 10 Feb 2009) | 25 lines
 
 Merged revisions 174583 via svnmerge from
 https://origsvn.digium.com/svn/asterisk/branches/1.4
 
 ........
   r174583 | mnicholson | 2009-02-10 11:52:42 -0600 (Tue, 10 Feb 2009) | 18 lines
   
   Improve behavior of jitterbuffer when maxjitterbuffer is set.
   
   This change improves the way the jitterbuffer handles maxjitterbuffer and
   dramatically reduces the number of frames dropped when maxjitterbuffer is
   exceeded.  In the previous jitterbuffer, when maxjitterbuffer was exceeded, all
   new frames were dropped until the jitterbuffer is empty.  This change modifies
   the code to only drop frames until maxjitterbuffer is no longer exceeded.
   
   Also, previously when maxjitterbuffer was exceeded, dropped frames were not
   tracked causing stats for dropped frames to be incorrect, this change also
   addresses that problem.
   
   (closes issue ASTERISK-13188)
   Patches:
         bug14044-1.diff uploaded by mnicholson (license 96)
   Tested by: mnicholson
   Review: http://reviewboard.digium.com/r/144/
 ........
................

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=174590

By: Digium Subversion (svnbot) 2009-02-10 12:19:52.000-0600

Repository: asterisk
Revision: 174596

_U  branches/1.6.0/
U   branches/1.6.0/main/jitterbuf.c

------------------------------------------------------------------------
r174596 | mnicholson | 2009-02-10 12:19:51 -0600 (Tue, 10 Feb 2009) | 32 lines

Merged revisions 174584 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
 r174584 | mnicholson | 2009-02-10 12:16:31 -0600 (Tue, 10 Feb 2009) | 25 lines
 
 Merged revisions 174583 via svnmerge from
 https://origsvn.digium.com/svn/asterisk/branches/1.4
 
 ........
   r174583 | mnicholson | 2009-02-10 11:52:42 -0600 (Tue, 10 Feb 2009) | 18 lines
   
   Improve behavior of jitterbuffer when maxjitterbuffer is set.
   
   This change improves the way the jitterbuffer handles maxjitterbuffer and
   dramatically reduces the number of frames dropped when maxjitterbuffer is
   exceeded.  In the previous jitterbuffer, when maxjitterbuffer was exceeded, all
   new frames were dropped until the jitterbuffer is empty.  This change modifies
   the code to only drop frames until maxjitterbuffer is no longer exceeded.
   
   Also, previously when maxjitterbuffer was exceeded, dropped frames were not
   tracked causing stats for dropped frames to be incorrect, this change also
   addresses that problem.
   
   (closes issue ASTERISK-13188)
   Patches:
         bug14044-1.diff uploaded by mnicholson (license 96)
   Tested by: mnicholson
   Review: http://reviewboard.digium.com/r/144/
 ........
................

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=174596