Home | History | Annotate | Download | only in libspeex

Lines Matching defs:stereo

2    File: stereo.c
66 /* This is an ugly compatibility hack that properly resets the stereo state
77 SpeexStereoState *stereo = speex_alloc(sizeof(SpeexStereoState));
78 speex_stereo_state_reset(stereo);
79 return stereo;
84 RealSpeexStereoState *stereo = (RealSpeexStereoState*)_stereo;
86 stereo->balance = 65536;
87 stereo->e_ratio = 16384;
88 stereo->smooth_left = 16384;
89 stereo->smooth_right = 16384;
90 stereo->reserved1 = 0xdeadbeef;
91 stereo->reserved2 = 0;
93 stereo->balance = 1.0f;
94 stereo->e_ratio = .5f;
95 stereo->smooth_left = 1.f;
96 stereo->smooth_right = 1.f;
97 stereo->reserved1 = 0;
98 stereo->reserved2 = 0;
102 EXPORT void speex_stereo_state_destroy(SpeexStereoState *stereo)
104 speex_free(stereo);
159 /* Stereo marker */
226 RealSpeexStereoState *stereo = (RealSpeexStereoState*)_stereo;
228 COMPATIBILITY_HACK(stereo);
230 balance=stereo->balance;
231 e_ratio=stereo->e_ratio;
240 stereo->smooth_left = EXTRACT16(PSHR32(MAC16_16(MULT16_16(stereo->smooth_left, QCONST16(0.98, 15)), e_left, QCONST16(0.02, 15)), 15));
241 stereo->smooth_right = EXTRACT16(PSHR32(MAC16_16(MULT16_16(stereo->smooth_right, QCONST16(0.98, 15)), e_right, QCONST16(0.02, 15)), 15));
242 data[2*i] = (float)MULT16_16_P14(stereo->smooth_left, tmp);
243 data[2*i+1] = (float)MULT16_16_P14(stereo->smooth_right, tmp);
253 RealSpeexStereoState *stereo = (RealSpeexStereoState*)_stereo;
255 COMPATIBILITY_HACK(stereo);
257 balance=stereo->balance;
258 e_ratio=stereo->e_ratio;
267 stereo->smooth_left = EXTRACT16(PSHR32(MAC16_16(MULT16_16(stereo->smooth_left, QCONST16(0.98, 15)), e_left, QCONST16(0.02, 15)), 15));
268 stereo->smooth_right = EXTRACT16(PSHR32(MAC16_16(MULT16_16(stereo->smooth_right, QCONST16(0.98, 15)), e_right, QCONST16(0.02, 15)), 15));
269 data[2*i] = (spx_int16_t)MULT16_16_P14(stereo->smooth_left, tmp);
270 data[2*i+1] = (spx_int16_t)MULT16_16_P14(stereo->smooth_right, tmp);
276 RealSpeexStereoState *stereo;
280 stereo = (RealSpeexStereoState*)data;
282 COMPATIBILITY_HACK(stereo);
288 stereo->balance = exp(sign*.25*dexp);
290 stereo->balance = spx_exp(MULT16_16(sign, SHL16(dexp, 9)));
293 stereo->e_ratio = e_ratio_quant[tmp];