]> code.delx.au - pulseaudio/blobdiff - src/modules/echo-cancel/echo-cancel.h
echo-cancel: Add the WebRTC echo canceller
[pulseaudio] / src / modules / echo-cancel / echo-cancel.h
index 9f679807454f2cb23603dc62d38333cae36e19e1..19e13505a43bd41a2a15c20648f758b31c5ca874 100644 (file)
@@ -49,6 +49,15 @@ struct pa_echo_canceller_params {
             uint32_t blocksize;
             AEC *aec;
         } adrian;
+#ifdef HAVE_WEBRTC
+        struct {
+            /* This is a void* so that we don't have to convert this whole file
+             * to C++ linkage. apm is a pointer to an AudioProcessing object */
+            void *apm;
+            uint32_t blocksize;
+            pa_sample_spec sample_spec;
+        } webrtc;
+#endif
         /* each canceller-specific structure goes here */
     } priv;
 };
@@ -86,4 +95,16 @@ pa_bool_t pa_adrian_ec_init(pa_core *c, pa_echo_canceller *ec,
 void pa_adrian_ec_run(pa_echo_canceller *ec, const uint8_t *rec, const uint8_t *play, uint8_t *out);
 void pa_adrian_ec_done(pa_echo_canceller *ec);
 
+#ifdef HAVE_WEBRTC
+/* WebRTC canceller functions */
+PA_C_DECL_BEGIN
+pa_bool_t pa_webrtc_ec_init(pa_core *c, pa_echo_canceller *ec,
+                            pa_sample_spec *source_ss, pa_channel_map *source_map,
+                            pa_sample_spec *sink_ss, pa_channel_map *sink_map,
+                            uint32_t *blocksize, const char *args);
+void pa_webrtc_ec_run(pa_echo_canceller *ec, const uint8_t *rec, const uint8_t *play, uint8_t *out);
+void pa_webrtc_ec_done(pa_echo_canceller *ec);
+PA_C_DECL_END
+#endif
+
 #endif /* fooechocancelhfoo */