echo-cancel: Move speex preprocessing out of the main module

I initially included put the Speex preprocessing assuming that we'd want
to use the digital gain control and noise suppression from Speex for all
echo cancelling implementations. In practice, we're probably going to
get entire implementations all processing in one package (WebRTC, custom
modules from various vendors, etc.).

This moves out this preprocessing and related knobs into the speex
implementation, which serves to clean out all implementation-specific
details from the module-echo-cancel core.
This commit is contained in:
Arun Raghavan 2011-08-25 17:47:05 +05:30
parent af6229cbe1
commit 7dfb166dba
3 changed files with 117 additions and 98 deletions

View file

@ -43,6 +43,7 @@ struct pa_echo_canceller_params {
union {
struct {
SpeexEchoState *state;
SpeexPreprocessState *pp_state;
} speex;
struct {
uint32_t blocksize;
@ -67,13 +68,6 @@ struct pa_echo_canceller {
void (*done) (pa_echo_canceller *ec);
pa_echo_canceller_params params;
pa_bool_t agc;
pa_bool_t denoise;
pa_bool_t echo_suppress;
int32_t echo_suppress_attenuation;
int32_t echo_suppress_attenuation_active;
SpeexPreprocessState *pp_state;
};
/* Speex canceller functions */