FFmpeg
Functions | Variables
sndio_dec.c File Reference
#include <stdint.h>
#include <sndio.h>
#include "libavutil/internal.h"
#include "libavutil/opt.h"
#include "libavutil/time.h"
#include "libavformat/avformat.h"
#include "libavformat/internal.h"

Go to the source code of this file.

Functions

static av_cold int audio_read_header (AVFormatContext *s1)
 
static int audio_read_packet (AVFormatContext *s1, AVPacket *pkt)
 
static av_cold int audio_read_close (AVFormatContext *s1)
 

Variables

static const AVOption options []
 
static const AVClass sndio_demuxer_class
 
const AVInputFormat ff_sndio_demuxer
 

Function Documentation

◆ audio_read_header()

static av_cold int audio_read_header ( AVFormatContext s1)
static

Definition at line 34 of file sndio_dec.c.

◆ audio_read_packet()

static int audio_read_packet ( AVFormatContext s1,
AVPacket pkt 
)
static

Definition at line 59 of file sndio_dec.c.

◆ audio_read_close()

static av_cold int audio_read_close ( AVFormatContext s1)
static

Definition at line 89 of file sndio_dec.c.

Variable Documentation

◆ options

const AVOption options[]
static
Initial value:
= {
{ "sample_rate", "", 0x42, AV_OPT_TYPE_INT, {.i64 = 48000}, 1, INT_MAX, AV_OPT_FLAG_DECODING_PARAM },
{ "channels", "", 0x42, AV_OPT_TYPE_INT, {.i64 = 2}, 1, INT_MAX, AV_OPT_FLAG_DECODING_PARAM },
{ NULL },
}

Definition at line 98 of file sndio_dec.c.

◆ sndio_demuxer_class

const AVClass sndio_demuxer_class
static
Initial value:
= {
.class_name = "sndio indev",
.item_name = av_default_item_name,
.option = options,
}

Definition at line 104 of file sndio_dec.c.

◆ ff_sndio_demuxer

const AVInputFormat ff_sndio_demuxer
Initial value:
= {
.name = "sndio",
.long_name = NULL_IF_CONFIG_SMALL("sndio audio capture"),
.priv_data_size = sizeof(SndioData),
.priv_class = &sndio_demuxer_class,
}

Definition at line 112 of file sndio_dec.c.

audio_read_close
static av_cold int audio_read_close(AVFormatContext *s1)
Definition: sndio_dec.c:89
sndio_demuxer_class
static const AVClass sndio_demuxer_class
Definition: sndio_dec.c:104
read_close
static av_cold int read_close(AVFormatContext *ctx)
Definition: libcdio.c:143
AV_CLASS_CATEGORY_DEVICE_AUDIO_INPUT
@ AV_CLASS_CATEGORY_DEVICE_AUDIO_INPUT
Definition: log.h:43
read_packet
static int read_packet(void *opaque, uint8_t *buf, int buf_size)
Definition: avio_read_callback.c:41
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
read_header
static int read_header(FFV1Context *f)
Definition: ffv1dec.c:545
NULL
#define NULL
Definition: coverity.c:32
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:237
SndioData
Definition: sndio.h:31
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:115
AVFMT_NOFILE
#define AVFMT_NOFILE
Demuxer will use avio_open, no opened file should be provided by the caller.
Definition: avformat.h:468
AV_OPT_FLAG_DECODING_PARAM
#define AV_OPT_FLAG_DECODING_PARAM
a generic parameter which can be set by the user for demuxing or decoding
Definition: opt.h:282
audio_read_header
static av_cold int audio_read_header(AVFormatContext *s1)
Definition: sndio_dec.c:34
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Definition: opt.h:225
options
static const AVOption options[]
Definition: sndio_dec.c:98
flags
#define flags(name, subs,...)
Definition: cbs_av1.c:561
audio_read_packet
static int audio_read_packet(AVFormatContext *s1, AVPacket *pkt)
Definition: sndio_dec.c:59