00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef QEMU_MIXENG_H
00025 #define QEMU_MIXENG_H
00026
00027 #ifdef FLOAT_MIXENG
00028 typedef float mixeng_real;
00029 struct mixeng_volume { int mute; mixeng_real r; mixeng_real l; };
00030 struct mixeng_sample { mixeng_real l; mixeng_real r; };
00031 #else
00032 struct mixeng_volume { int mute; int64_t r; int64_t l; };
00033 struct st_sample { int64_t l; int64_t r; };
00034 #endif
00035
00036 typedef void (t_sample) (struct st_sample *dst, const void *src,
00037 int samples, struct mixeng_volume *vol);
00038 typedef void (f_sample) (void *dst, const struct st_sample *src, int samples);
00039
00040 extern t_sample *mixeng_conv[2][2][2][3];
00041 extern f_sample *mixeng_clip[2][2][2][3];
00042
00043 void *st_rate_start (int inrate, int outrate);
00044 void st_rate_flow (void *opaque, struct st_sample *ibuf, struct st_sample *obuf,
00045 int *isamp, int *osamp);
00046 void st_rate_flow_mix (void *opaque, struct st_sample *ibuf, struct st_sample *obuf,
00047 int *isamp, int *osamp);
00048 void st_rate_stop (void *opaque);
00049 void mixeng_clear (struct st_sample *buf, int len);
00050
00051 #endif