1 #ifndef MPLAYER_AUDIO_IN_H
2 #define MPLAYER_AUDIO_IN_H
4 #define AUDIO_IN_ALSA 1
10 #include <alsa/asoundlib.h>
17 int buffer_time
, period_time
, chunk_size
;
18 size_t bits_per_sample
, bits_per_frame
;
22 #ifdef CONFIG_OSS_AUDIO
35 /* requested values */
39 /* real values read-only */
49 #ifdef CONFIG_OSS_AUDIO
54 int audio_in_init(audio_in_t
*ai
, int type
);
55 int audio_in_setup(audio_in_t
*ai
);
56 int audio_in_set_device(audio_in_t
*ai
, char *device
);
57 int audio_in_set_samplerate(audio_in_t
*ai
, int rate
);
58 int audio_in_set_channels(audio_in_t
*ai
, int channels
);
59 int audio_in_uninit(audio_in_t
*ai
);
60 int audio_in_start_capture(audio_in_t
*ai
);
61 int audio_in_read_chunk(audio_in_t
*ai
, unsigned char *buffer
);
64 int ai_alsa_setup(audio_in_t
*ai
);
65 int ai_alsa_init(audio_in_t
*ai
);
66 int ai_alsa_xrun(audio_in_t
*ai
);
69 #ifdef CONFIG_OSS_AUDIO
70 int ai_oss_set_samplerate(audio_in_t
*ai
);
71 int ai_oss_set_channels(audio_in_t
*ai
);
72 int ai_oss_init(audio_in_t
*ai
);
75 #endif /* MPLAYER_AUDIO_IN_H */