Mercurial > libavcodec.hg
comparison celp_filters.h @ 10003:24952f1a8979 libavcodec
cosmetics: K&R coding style
author | diego |
---|---|
date | Sun, 02 Aug 2009 10:34:30 +0000 |
parents | 2838045383c5 |
children | d35904b4fe3f |
comparison
equal
deleted
inserted
replaced
10002:878d449793e1 | 10003:24952f1a8979 |
---|---|
34 * | 34 * |
35 * fc_out[n] = sum(i,0,len-1){ fc_in[i] * filter[(len + n - i)%len] } | 35 * fc_out[n] = sum(i,0,len-1){ fc_in[i] * filter[(len + n - i)%len] } |
36 * | 36 * |
37 * \note fc_in and fc_out should not overlap! | 37 * \note fc_in and fc_out should not overlap! |
38 */ | 38 */ |
39 void ff_celp_convolve_circ( | 39 void ff_celp_convolve_circ(int16_t* fc_out, |
40 int16_t* fc_out, | 40 const int16_t* fc_in, |
41 const int16_t* fc_in, | 41 const int16_t* filter, |
42 const int16_t* filter, | 42 int len); |
43 int len); | |
44 | 43 |
45 /** | 44 /** |
46 * LP synthesis filter. | 45 * LP synthesis filter. |
47 * @param out [out] pointer to output buffer | 46 * @param out [out] pointer to output buffer |
48 * @param filter_coeffs filter coefficients (-0x8000 <= (3.12) < 0x8000) | 47 * @param filter_coeffs filter coefficients (-0x8000 <= (3.12) < 0x8000) |
58 * @note Output buffer must contain filter_length samples of past | 57 * @note Output buffer must contain filter_length samples of past |
59 * speech data before pointer. | 58 * speech data before pointer. |
60 * | 59 * |
61 * Routine applies 1/A(z) filter to given speech data. | 60 * Routine applies 1/A(z) filter to given speech data. |
62 */ | 61 */ |
63 int ff_celp_lp_synthesis_filter( | 62 int ff_celp_lp_synthesis_filter(int16_t *out, |
64 int16_t *out, | 63 const int16_t* filter_coeffs, |
65 const int16_t* filter_coeffs, | 64 const int16_t* in, |
66 const int16_t* in, | 65 int buffer_length, |
67 int buffer_length, | 66 int filter_length, |
68 int filter_length, | 67 int stop_on_overflow, |
69 int stop_on_overflow, | 68 int rounder); |
70 int rounder); | |
71 | 69 |
72 /** | 70 /** |
73 * LP synthesis filter. | 71 * LP synthesis filter. |
74 * @param out [out] pointer to output buffer | 72 * @param out [out] pointer to output buffer |
75 * - the array out[-filter_length, -1] must | 73 * - the array out[-filter_length, -1] must |
82 * @note Output buffer must contain filter_length samples of past | 80 * @note Output buffer must contain filter_length samples of past |
83 * speech data before pointer. | 81 * speech data before pointer. |
84 * | 82 * |
85 * Routine applies 1/A(z) filter to given speech data. | 83 * Routine applies 1/A(z) filter to given speech data. |
86 */ | 84 */ |
87 void ff_celp_lp_synthesis_filterf( | 85 void ff_celp_lp_synthesis_filterf(float *out, |
88 float *out, | 86 const float* filter_coeffs, |
89 const float* filter_coeffs, | 87 const float* in, |
90 const float* in, | 88 int buffer_length, |
91 int buffer_length, | 89 int filter_length); |
92 int filter_length); | |
93 | 90 |
94 /** | 91 /** |
95 * LP zero synthesis filter. | 92 * LP zero synthesis filter. |
96 * @param out [out] pointer to output buffer | 93 * @param out [out] pointer to output buffer |
97 * @param filter_coeffs filter coefficients. | 94 * @param filter_coeffs filter coefficients. |
104 * @note Output buffer must contain filter_length samples of past | 101 * @note Output buffer must contain filter_length samples of past |
105 * speech data before pointer. | 102 * speech data before pointer. |
106 * | 103 * |
107 * Routine applies A(z) filter to given speech data. | 104 * Routine applies A(z) filter to given speech data. |
108 */ | 105 */ |
109 void ff_celp_lp_zero_synthesis_filterf( | 106 void ff_celp_lp_zero_synthesis_filterf(float *out, |
110 float *out, | 107 const float* filter_coeffs, |
111 const float* filter_coeffs, | 108 const float* in, |
112 const float* in, | 109 int buffer_length, |
113 int buffer_length, | 110 int filter_length); |
114 int filter_length); | |
115 | 111 |
116 #endif /* AVCODEC_CELP_FILTERS_H */ | 112 #endif /* AVCODEC_CELP_FILTERS_H */ |