aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorqwell <qwell@f38db490-d61c-443f-a65b-d21fe96a405b>2008-03-26 23:28:00 +0000
committerqwell <qwell@f38db490-d61c-443f-a65b-d21fe96a405b>2008-03-26 23:28:00 +0000
commitae2f2e4dc35ff19676262e8ff7d7e7b43c03ae91 (patch)
tree467362a13b56cccb3c06e64f03b9d7c42320e03f /main
parent360207365e678a1afba9c8d9be099cc04e0e42f5 (diff)
Merged revisions 111246 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ................ r111246 | qwell | 2008-03-26 18:27:33 -0500 (Wed, 26 Mar 2008) | 17 lines Merged revisions 111245 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r111245 | qwell | 2008-03-26 18:26:33 -0500 (Wed, 26 Mar 2008) | 9 lines Remove excessive smoother optimization that was causing audio glitches (small "pops") after (about 200ms later) an "incorrectly" sized frame was received. While it would be very nice to keep this as optimized as possible, it makes no sense for the smoother to be dropping random bits of audio like this. Isn't that the whole point of a smoother? Closes issue #12093. ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@111247 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main')
-rw-r--r--main/frame.c18
1 files changed, 1 insertions, 17 deletions
diff --git a/main/frame.c b/main/frame.c
index f2ceabf16..3971393fd 100644
--- a/main/frame.c
+++ b/main/frame.c
@@ -85,7 +85,6 @@ struct ast_smoother {
int size;
int format;
int readdata;
- int optimizablestream;
int flags;
float samplesperbyte;
struct ast_frame f;
@@ -182,23 +181,8 @@ int __ast_smoother_feed(struct ast_smoother *s, struct ast_frame *f, int swap)
ast_swapcopy_samples(f->data, f->data, f->samples);
s->opt = f;
return 0;
- } else {
- s->optimizablestream++;
- if (s->optimizablestream > 10) {
- /* For the past 10 rounds, we have input and output
- frames of the correct size for this smoother, yet
- we were unable to optimize because there was still
- some cruft left over. Lets just drop the cruft so
- we can move to a fully optimized path */
- if (swap)
- ast_swapcopy_samples(f->data, f->data, f->samples);
- s->len = 0;
- s->opt = f;
- return 0;
- }
}
- } else
- s->optimizablestream = 0;
+ }
if (s->flags & AST_SMOOTHER_FLAG_G729) {
if (s->len % 10) {
ast_log(LOG_NOTICE, "Dropping extra frame of G.729 since we already have a VAD frame at the end\n");