[Speex-dev] echo residue buffer size

Jean-Marc Valin jean-marc.valin at usherbrooke.ca
Tue Nov 7 16:42:48 PST 2006

> Specifically, speex_get_echo_residual function fills up (frame_size + 1)
> elements. It's entirely possible (and even likely) that I'm missing
> something but isn't it supposed to use frame_size elements?

No, if should really be (frame_size + 1) because it includes both the DC
and the Nyquist frequency. But in any case, you don't need to worry
about it anymore because it's all hidden in the new API. All you need to
call is speex_echo_cancellation() and speex_preprocess_run().

Actually, you can even use speex_echo_playback() and speex_echo_cancel()
instead of speex_echo_cancellation() so that you don't need to do the
buffering yourself and the AEC will automatically delay the playback by
two frames to compensate for the soundcard delay.


More information about the Speex-dev mailing list