[Speex-dev] FFT Resampler

Alexander Chemeris Alexander.Chemeris at sipez.com
Thu May 29 05:35:48 PDT 2008

On 5/29/08, Thorvald Natvig <thorvald at natvig.com> wrote:
> > >  Yes, I plan to use it in a VoIP environment if I can get latency reduced to
> > > an acceptable level :)
> > >  The latency depends directly on the overlap parameter, which also controls
> > > the quality. Higher quality => higher latency. You could set the overlap to
> > > 0, but that would give you some nasty artifacts.
> > >  You can also resample with smaller block sizes. In the example I used
> 20ms
> > > blocks and 50% overlap. If you use 10ms blocks and 50% overlap, latency
> > > sinks to 5ms.
> >
> > How quality and CPU usage depends from block size?
> > Looking at edge case - 1 sample blocks - I should have <1 sample latency,
> > but something should be  wrong here, e.g. required CPU power may be
> > infinite, no? :)
> >
> >
>  Higher block size and more overlap => higher CPU. The idea is to let the
> block size be whatever block size you use for the rest of your program. For
> Speex, 20ms is perfect.
>  Lower overlap will give less CPU requirements, but also introduce artifacts
> in the resampling.

Do you mean that using 10ms frames with 50% overlap will give you worse
quality then 20ms frames with 50% overlap, like when you're using 25%
overlap? Else, why not to work on smaller 10ms frames instead of 20ms
frames, or even 5ms frames - from your words it follows that you'll get
smaller latency and CPU usage in this case.
If I'm correct, it seems to better talk about overlap in terms of samples/ms
then in terms of percents, or it will confuse a lot.

Alexander Chemeris.

SIP VoIP, IM and Presence Consulting
tel: +1 (617) 273-4000

More information about the Speex-dev mailing list