summaryrefslogtreecommitdiffstats
path: root/src/modules/echo-cancel/adrian-aec.h
diff options
context:
space:
mode:
authorArun Raghavan <arun.raghavan@collabora.co.uk>2010-09-21 20:42:32 +0530
committerArun Raghavan <arun.raghavan@collabora.co.uk>2010-09-23 17:17:03 +0530
commit963250abb99ab43b209281c2aa5398205492e555 (patch)
tree9f745ac8c630dd294c1a9a3c8255098526122117 /src/modules/echo-cancel/adrian-aec.h
parentab4223e9cffbc21399c0468dd89a2e57122fbfee (diff)
echo-cancel: Add SSE optimisation to the adrian module
Optimises the core inner-product function, which takes the most CPU. The SSE-optimised bits of the adrian echo canceller only if the CPU that PA is running on actually supports SSE.
Diffstat (limited to 'src/modules/echo-cancel/adrian-aec.h')
-rw-r--r--src/modules/echo-cancel/adrian-aec.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/modules/echo-cancel/adrian-aec.h b/src/modules/echo-cancel/adrian-aec.h
index 1f5b090a..df9f3e64 100644
--- a/src/modules/echo-cancel/adrian-aec.h
+++ b/src/modules/echo-cancel/adrian-aec.h
@@ -13,6 +13,13 @@
#ifndef _AEC_H /* include only once */
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <pulsecore/macro.h>
+#include <pulse/xmalloc.h>
+
#define WIDEB 2
// use double if your CPU does software-emulation of float
@@ -315,6 +322,9 @@ struct AEC {
// variables are public for visualization
int hangover;
float stepsize;
+
+ // vfuncs that are picked based on processor features available
+ REAL (*dotp) (REAL[], REAL[]);
};
/* Double-Talk Detector
@@ -338,7 +348,7 @@ static void AEC_leaky(AEC *a);
*/
static REAL AEC_nlms_pw(AEC *a, REAL d, REAL x_, float stepsize);
- AEC* AEC_init(int RATE);
+ AEC* AEC_init(int RATE, int have_vector);
/* Acoustic Echo Cancellation and Suppression of one sample
* in d: microphone signal with echo