25
25
#define QEMU_MIXENG_H
27
27
#ifdef FLOAT_MIXENG
29
typedef struct { int mute; real_t r; real_t l; } volume_t;
30
typedef struct { real_t l; real_t r; } st_sample_t;
28
typedef float mixeng_real;
29
struct mixeng_volume { int mute; mixeng_real r; mixeng_real l; };
30
struct mixeng_sample { mixeng_real l; mixeng_real r; };
32
typedef struct { int mute; int64_t r; int64_t l; } volume_t;
33
typedef struct { int64_t l; int64_t r; } st_sample_t;
32
struct mixeng_volume { int mute; int64_t r; int64_t l; };
33
struct st_sample { int64_t l; int64_t r; };
36
typedef void (t_sample) (st_sample_t *dst, const void *src,
37
int samples, volume_t *vol);
38
typedef void (f_sample) (void *dst, const st_sample_t *src, int samples);
36
typedef void (t_sample) (struct st_sample *dst, const void *src,
37
int samples, struct mixeng_volume *vol);
38
typedef void (f_sample) (void *dst, const struct st_sample *src, int samples);
40
40
extern t_sample *mixeng_conv[2][2][2][3];
41
41
extern f_sample *mixeng_clip[2][2][2][3];
43
43
void *st_rate_start (int inrate, int outrate);
44
void st_rate_flow (void *opaque, st_sample_t *ibuf, st_sample_t *obuf,
44
void st_rate_flow (void *opaque, struct st_sample *ibuf, struct st_sample *obuf,
45
45
int *isamp, int *osamp);
46
void st_rate_flow_mix (void *opaque, st_sample_t *ibuf, st_sample_t *obuf,
46
void st_rate_flow_mix (void *opaque, struct st_sample *ibuf, struct st_sample *obuf,
47
47
int *isamp, int *osamp);
48
48
void st_rate_stop (void *opaque);
49
void mixeng_clear (st_sample_t *buf, int len);
49
void mixeng_clear (struct st_sample *buf, int len);
51
51
#endif /* mixeng.h */