00001
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #ifndef SPEEX_ECHO_H
00035 #define SPEEX_ECHO_H
00036
00040 #include "speex/speex_types.h"
00041
00042 #ifdef __cplusplus
00043 extern "C" {
00044 #endif
00045
00047 #define SPEEX_ECHO_GET_FRAME_SIZE 3
00048
00050 #define SPEEX_ECHO_SET_SAMPLING_RATE 24
00051
00052 #define SPEEX_ECHO_GET_SAMPLING_RATE 25
00053
00055 struct SpeexEchoState_;
00056
00062 typedef struct SpeexEchoState_ SpeexEchoState;
00063
00069 SpeexEchoState *speex_echo_state_init(int frame_size, int filter_length);
00070
00074 void speex_echo_state_destroy(SpeexEchoState *st);
00075
00084 void speex_echo_cancellation(SpeexEchoState *st, const spx_int16_t *rec, const spx_int16_t *play, spx_int16_t *out);
00085
00087 void speex_echo_cancel(SpeexEchoState *st, const spx_int16_t *rec, const spx_int16_t *play, spx_int16_t *out, spx_int32_t *Yout);
00088
00095 void speex_echo_capture(SpeexEchoState *st, const spx_int16_t *rec, spx_int16_t *out);
00096
00101 void speex_echo_playback(SpeexEchoState *st, const spx_int16_t *play);
00102
00106 void speex_echo_state_reset(SpeexEchoState *st);
00107
00115 int speex_echo_ctl(SpeexEchoState *st, int request, void *ptr);
00116
00117 #ifdef __cplusplus
00118 }
00119 #endif
00120
00121
00123 #endif