Mercurial > mplayer.hg
annotate libao2/audio_out.h @ 17815:36a155ee4d27
init delta_pts before using it; fixes cid 239
author | nicodvb |
---|---|
date | Sat, 11 Mar 2006 23:21:09 +0000 |
parents | f580a7755ac5 |
children | 93dd2847bcdc |
rev | line source |
---|---|
6795 | 1 |
2 #ifndef __AUDIO_OUT_H | |
3 #define __AUDIO_OUT_H | |
4 | |
954 | 5 typedef struct ao_info_s |
6 { | |
7 /* driver name ("Matrox Millennium G200/G400" */ | |
8 const char *name; | |
9 /* short name (for config strings) ("mga") */ | |
10 const char *short_name; | |
11 /* author ("Aaron Holtzman <aholtzma@ess.engr.uvic.ca>") */ | |
12 const char *author; | |
13 /* any additional comments */ | |
14 const char *comment; | |
15 } ao_info_t; | |
16 | |
3095 | 17 /* interface towards mplayer and */ |
1127
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
18 typedef struct ao_functions_s |
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
19 { |
954 | 20 ao_info_t *info; |
9633
12b1790038b0
64bit libao2 fix by Jens Axboe <mplayer-dev@kernel.dk>
alex
parents:
7563
diff
changeset
|
21 int (*control)(int cmd,void *arg); |
954 | 22 int (*init)(int rate,int channels,int format,int flags); |
12145 | 23 void (*uninit)(int immed); |
17566
f580a7755ac5
Patch by Stefan Huehner / stefan % huehner ! org \
rathann
parents:
14618
diff
changeset
|
24 void (*reset)(void); |
f580a7755ac5
Patch by Stefan Huehner / stefan % huehner ! org \
rathann
parents:
14618
diff
changeset
|
25 int (*get_space)(void); |
1127
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
26 int (*play)(void* data,int len,int flags); |
17566
f580a7755ac5
Patch by Stefan Huehner / stefan % huehner ! org \
rathann
parents:
14618
diff
changeset
|
27 float (*get_delay)(void); |
f580a7755ac5
Patch by Stefan Huehner / stefan % huehner ! org \
rathann
parents:
14618
diff
changeset
|
28 void (*pause)(void); |
f580a7755ac5
Patch by Stefan Huehner / stefan % huehner ! org \
rathann
parents:
14618
diff
changeset
|
29 void (*resume)(void); |
1127
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
30 } ao_functions_t; |
954 | 31 |
3095 | 32 /* global data used by mplayer and plugins */ |
33 typedef struct ao_data_s | |
34 { | |
35 int samplerate; | |
36 int channels; | |
37 int format; | |
38 int bps; | |
39 int outburst; | |
40 int buffersize; | |
41 int pts; | |
42 } ao_data_t; | |
43 | |
44 extern char *ao_subdevice; | |
45 extern ao_data_t ao_data; | |
46 | |
17566
f580a7755ac5
Patch by Stefan Huehner / stefan % huehner ! org \
rathann
parents:
14618
diff
changeset
|
47 void list_audio_out(void); |
7563
e9e4398029de
audio out driver list support (example: -ao alsa9,sdl:esd,oss,sdl:oss,)
arpi
parents:
6795
diff
changeset
|
48 ao_functions_t* init_best_audio_out(char** ao_list,int use_plugin,int rate,int channels,int format,int flags); |
e9e4398029de
audio out driver list support (example: -ao alsa9,sdl:esd,oss,sdl:oss,)
arpi
parents:
6795
diff
changeset
|
49 |
954 | 50 // NULL terminated array of all drivers |
51 extern ao_functions_t* audio_out_drivers[]; | |
52 | |
53 #define CONTROL_OK 1 | |
54 #define CONTROL_TRUE 1 | |
55 #define CONTROL_FALSE 0 | |
56 #define CONTROL_UNKNOWN -1 | |
57 #define CONTROL_ERROR -2 | |
58 #define CONTROL_NA -3 | |
59 | |
60 #define AOCONTROL_SET_DEVICE 1 | |
1048 | 61 #define AOCONTROL_GET_DEVICE 2 |
1127
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
62 #define AOCONTROL_QUERY_FORMAT 3 /* test for availabilty of a format */ |
1048 | 63 #define AOCONTROL_GET_VOLUME 4 |
64 #define AOCONTROL_SET_VOLUME 5 | |
3107 | 65 #define AOCONTROL_SET_PLUGIN_DRIVER 6 |
66 #define AOCONTROL_SET_PLUGIN_LIST 7 | |
1127
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
67 |
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
68 typedef struct ao_control_vol_s { |
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
69 float left; |
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
70 float right; |
ca1bc9edf735
audio_out_format_name prototype added, ao_control_vol_t for aocontrol_get/set_volume added
al3x
parents:
1048
diff
changeset
|
71 } ao_control_vol_t; |
3107 | 72 |
6795 | 73 #endif |