]> code.delx.au - pulseaudio/commit
echo-cancel: Plug in WebRTC drift compensation
authorArun Raghavan <arun.raghavan@collabora.co.uk>
Fri, 7 Oct 2011 10:58:11 +0000 (16:28 +0530)
committerArun Raghavan <arun.raghavan@collabora.co.uk>
Tue, 1 Nov 2011 12:50:32 +0000 (18:20 +0530)
commit23ce9a4f7910d52e07403049b40ee226622a5f36
treee54ea43227e480ad7b33733b050f4041f174d2a7
parent8c0cca79058c2e669a6b02ea503514926e795981
echo-cancel: Plug in WebRTC drift compensation

This adds the ability for echo cancellers to provide their own drift
compensation, and hooks in the appropriate bits to implement this in the
WebRTC canceller.

We do this by introducing an alternative model for the canceller. So
far, the core engine just provided a run() method which was given
blocksize-sized chunks of playback and record samples. The new model has
the engine provide play() and record() methods that can (in theory) be
called by the playback and capture threads. The latter would actually do
the processing required.

In addition to this a set_drift() method may be provided by the
implementation. PA will provide periodic samples of the drift to the
engine. These values need to be aggregated and processed over some time,
since the point values vary quite a bit (but generally fit a linear
regression reasonably accurately). At some point of time, we might move
the actual drift calculation into PA and change the semantics of this
function.

NOTE: This needs further testing before being deemed ready for wider use.
src/modules/echo-cancel/echo-cancel.h
src/modules/echo-cancel/module-echo-cancel.c
src/modules/echo-cancel/webrtc.cc