[Speex-dev] JitterBuffer in SVN

Jean-Marc Valin jean-marc.valin at usherbrooke.ca
Wed Nov 14 22:43:58 PST 2007


> I added some logging to my last debug build, but users stopped using it
> and rolled back to the previous version due to all the printfs. I see
> these are now removed, so I'll do a new build. However, is there any
> chance you could change to spxprintf() or something similar which we
> could override easily? This would reduce the amount of "errors" reported
> to users (who then report it as a bug to me), and would also allow me to
> capture the output and include it in the autogenerated bugreports if
> there are any problems.

Actually, the printfs shouldn't have been there in the first place. I
might introduce a debug_print() in the future (disabled by default), but
that's another topic. I'm also planning on adding optional call logging
in the jitter buffer to make it easy for me or anyone to reproduce
what's happening in someone's setup.

About the jitter buffer itself, I've just completely changed the
decision algorithm to make it more adaptable to all kinds of applications.

The API didn't change, but I added some new parameters:
- JITTER_BUFFER_SET_MAX_LATE_RATE: Absolute max percentage of late
frames allowed, no matter what the delay is (defaults to 4 percent)
- JITTER_BUFFER_SET_LATE_COST: Controls the delay/loss tradeoff. For
example, if set to 160, it means that one percent loss is as bad as 160
timestamp units (samples). By default, the jitter buffer tries to be
"intelligent".

Also, JITTER_BUFFER_SET_MARGIN is now in timestamp units, not in
blocks/ticks.

There's still a few minor changes I want to make, but most of it is done
now. Please give me some feedback on how good (or bad) the new algorithm
works.

Cheers,

	Jean-Marc


More information about the Speex-dev mailing list