Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/xiph/speex.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Marc Valin <Jean-Marc.Valin@csiro.au>2008-06-04 11:00:08 +0400
committerJean-Marc Valin <Jean-Marc.Valin@csiro.au>2008-06-04 11:00:08 +0400
commit3d5c97908a77adc1d052069e4b53598b5aef96ec (patch)
tree277de997c8200d0279ebf08793ea498e9c8ccd4f /include
parent9453b831d39999a09e81c5c190e69c8ee6af2317 (diff)
Integrating the decorrelation API with the echo canceller (speex_echo.h)
Diffstat (limited to 'include')
-rw-r--r--include/speex/speex_echo.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/include/speex/speex_echo.h b/include/speex/speex_echo.h
index 1970af4..fec17e4 100644
--- a/include/speex/speex_echo.h
+++ b/include/speex/speex_echo.h
@@ -131,6 +131,36 @@ void speex_echo_state_reset(SpeexEchoState *st);
*/
int speex_echo_ctl(SpeexEchoState *st, int request, void *ptr);
+
+
+struct DecorrState_;
+
+typedef struct DecorrState_ DecorrState;
+
+
+/** Create a state for the channel decorrelation algorithm
+ This is useful for multi-channel echo cancellation only
+ * @param rate Sampling rate
+ * @param channels Number of channels (it's a bit pointless if you don't have at least 2)
+ * @param frame_size Size of the frame to process at ones (counting samples *per* channel)
+*/
+DecorrState *speex_decorrelate_new(int rate, int channels, int frame_size);
+
+/** Remove correlation between the channels by modifying the phase and possibly
+ adding noise in a way that is not (or little) perceptible.
+ * @param st Decorrelator state
+ * @param in Input audio in interleaved format
+ * @param out Result of the decorrelation (out *may* alias in)
+ * @param strength How much alteration of the audio to apply from 0 to 100.
+*/
+void speex_decorrelate(DecorrState *st, const spx_int16_t *in, spx_int16_t *out, int strength);
+
+/** Destroy a Decorrelation state
+ * @param st State to destroy
+*/
+void speex_decorrelate_destroy(DecorrState *st);
+
+
#ifdef __cplusplus
}
#endif