libavdevice/jack_audio.c File Reference

#include "config.h"
#include <semaphore.h>
#include <jack/jack.h>
#include "libavutil/log.h"
#include "libavutil/fifo.h"
#include "libavutil/opt.h"
#include "libavcodec/avcodec.h"
#include "libavformat/avformat.h"
#include "libavformat/internal.h"
#include "timefilter.h"
#include "avdevice.h"

Go to the source code of this file.

Data Structures

struct  JackData

Defines

#define FIFO_PACKETS_NUM   16
 Size of the internal FIFO buffers as a number of audio packets.
#define OFFSET(x)   offsetof(JackData, x)

Functions

static int process_callback (jack_nframes_t nframes, void *arg)
static void shutdown_callback (void *arg)
static int xrun_callback (void *arg)
static int supply_new_packets (JackData *self, AVFormatContext *context)
static int start_jack (AVFormatContext *context)
static void free_pkt_fifo (AVFifoBuffer *fifo)
static void stop_jack (JackData *self)
static int audio_read_header (AVFormatContext *context, AVFormatParameters *params)
static int audio_read_packet (AVFormatContext *context, AVPacket *pkt)
static int audio_read_close (AVFormatContext *context)

Variables

static const AVOption options []
static const AVClass jack_indev_class
AVInputFormat ff_jack_demuxer


Define Documentation

#define FIFO_PACKETS_NUM   16

Size of the internal FIFO buffers as a number of audio packets.

Definition at line 39 of file jack_audio.c.

Referenced by start_jack().

#define OFFSET (  )     offsetof(JackData, x)

Definition at line 317 of file jack_audio.c.


Function Documentation

static int audio_read_close ( AVFormatContext context  )  [static]

Definition at line 310 of file jack_audio.c.

static int audio_read_header ( AVFormatContext context,
AVFormatParameters params 
) [static]

Definition at line 225 of file jack_audio.c.

static int audio_read_packet ( AVFormatContext context,
AVPacket pkt 
) [static]

Definition at line 253 of file jack_audio.c.

static void free_pkt_fifo ( AVFifoBuffer fifo  )  [static]

Definition at line 201 of file jack_audio.c.

Referenced by stop_jack().

static int process_callback ( jack_nframes_t  nframes,
void *  arg 
) [static]

Definition at line 57 of file jack_audio.c.

Referenced by start_jack().

static void shutdown_callback ( void *  arg  )  [static]

Definition at line 111 of file jack_audio.c.

Referenced by start_jack().

static int start_jack ( AVFormatContext context  )  [static]

bandwidth: 1.5Hz

Definition at line 143 of file jack_audio.c.

Referenced by audio_read_header().

static void stop_jack ( JackData self  )  [static]

Definition at line 211 of file jack_audio.c.

Referenced by audio_read_close(), and audio_read_header().

static int supply_new_packets ( JackData self,
AVFormatContext context 
) [static]

Definition at line 125 of file jack_audio.c.

Referenced by audio_read_packet(), and start_jack().

static int xrun_callback ( void *  arg  )  [static]

Definition at line 117 of file jack_audio.c.

Referenced by start_jack().


Variable Documentation

Initial value:

 {
    .name           = "jack",
    .long_name      = NULL_IF_CONFIG_SMALL("JACK Audio Connection Kit"),
    .priv_data_size = sizeof(JackData),
    .read_header    = audio_read_header,
    .read_packet    = audio_read_packet,
    .read_close     = audio_read_close,
    .flags          = AVFMT_NOFILE,
    .priv_class     = &jack_indev_class,
}

Definition at line 330 of file jack_audio.c.

const AVClass jack_indev_class [static]

Initial value:

 {
    .class_name     = "JACK indev",
    .item_name      = av_default_item_name,
    .option         = options,
    .version        = LIBAVUTIL_VERSION_INT,
}

Definition at line 323 of file jack_audio.c.

const AVOption options[] [static]

Initial value:

 {
    { "channels", "Number of audio channels.", OFFSET(nports), AV_OPT_TYPE_INT, { 2 }, 1, INT_MAX, AV_OPT_FLAG_DECODING_PARAM },
    { NULL },
}

Definition at line 318 of file jack_audio.c.


Generated on Fri Oct 26 02:46:11 2012 for FFmpeg by  doxygen 1.5.8