Go to the documentation of this file.
30 #ifndef AVDEVICE_ALSA_H
31 #define AVDEVICE_ALSA_H
33 #include <alsa/asoundlib.h>
43 #define DEFAULT_CODEC_ID AV_NE(AV_CODEC_ID_PCM_S16BE, AV_CODEC_ID_PCM_S16LE)
47 #define ALSA_BUFFER_SIZE_MAX 131072
55 #if FF_API_ALSA_CHANNELS
84 unsigned int *sample_rate,
Opaque type representing a time filter state.
av_warn_unused_result int ff_alsa_open(AVFormatContext *s, snd_pcm_stream_t mode, unsigned int *sample_rate, const AVChannelLayout *layout, enum AVCodecID *codec_id)
Open an ALSA PCM.
av_warn_unused_result int ff_alsa_xrun_recover(AVFormatContext *s1, int err)
Try to recover from ALSA buffer underrun.
int64_t timestamp
current timestamp, without latency applied.
int sample_rate
sample rate set by user
int frame_size
bytes per sample * channels
AVChannelLayout ch_layout
Channel layout set by user.
av_warn_unused_result int ff_alsa_extend_reorder_buf(AlsaData *s, int size)
int ff_alsa_close(AVFormatContext *s1)
Close the ALSA PCM.
Describe the class of an AVClass context structure.
AVCodecID
Identify the syntax and semantics of the bitstream.
An AVChannelLayout holds information about the channel layout of audio data.
void(* reorder_func)(const void *, void *, int)
#define av_warn_unused_result
Filter the word “frame” indicates either a video frame or a group of audio as stored in an AVFrame structure Format for each input and each output the list of supported formats For video that means pixel format For audio that means channel layout
int reorder_buf_size
in frames
av_warn_unused_result int ff_alsa_get_device_list(AVDeviceInfoList *device_list, snd_pcm_stream_t stream_type)
int channels
number of channels set by user
This structure stores compressed data.
void(* ff_reorder_func)(const void *, void *, int)
int period_size
preferred size for reads and writes, in frames