FFmpeg
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
concatdec.c File Reference
#include "libavutil/avstring.h"
#include "libavutil/opt.h"
#include "libavutil/parseutils.h"
#include "avformat.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  ConcatFile
 
struct  ConcatContext
 

Macros

#define FAIL(retcode)   do { ret = (retcode); goto fail; } while(0)
 
#define OFFSET(x)   offsetof(ConcatContext, x)
 
#define DEC   AV_OPT_FLAG_DECODING_PARAM
 

Functions

static int concat_probe (AVProbeData *probe)
 
static char * get_keyword (uint8_t **cursor)
 
static int safe_filename (const char *f)
 
static int add_file (AVFormatContext *avf, char *filename, ConcatFile **rfile, unsigned *nb_files_alloc)
 
static int open_file (AVFormatContext *avf, unsigned fileno)
 
static int concat_read_close (AVFormatContext *avf)
 
static int concat_read_header (AVFormatContext *avf)
 
static int open_next_file (AVFormatContext *avf)
 
static int concat_read_packet (AVFormatContext *avf, AVPacket *pkt)
 

Variables

static const AVOption options []
 
static const AVClass concat_class
 
AVInputFormat ff_concat_demuxer
 

Macro Definition Documentation

#define FAIL (   retcode)    do { ret = (retcode); goto fail; } while(0)

Definition at line 78 of file concatdec.c.

Referenced by concat_read_header().

#define OFFSET (   x)    offsetof(ConcatContext, x)

Definition at line 279 of file concatdec.c.

#define DEC   AV_OPT_FLAG_DECODING_PARAM

Definition at line 280 of file concatdec.c.

Function Documentation

static int concat_probe ( AVProbeData probe)
static

Definition at line 42 of file concatdec.c.

static char* get_keyword ( uint8_t **  cursor)
static

Definition at line 48 of file concatdec.c.

Referenced by concat_read_header().

static int safe_filename ( const char *  f)
static

Definition at line 59 of file concatdec.c.

Referenced by add_file().

static int add_file ( AVFormatContext avf,
char *  filename,
ConcatFile **  rfile,
unsigned *  nb_files_alloc 
)
static

Definition at line 80 of file concatdec.c.

Referenced by concat_read_header().

static int open_file ( AVFormatContext avf,
unsigned  fileno 
)
static

Definition at line 119 of file concatdec.c.

Referenced by concat_read_header(), open_files(), and open_next_file().

static int concat_read_close ( AVFormatContext avf)
static

Definition at line 138 of file concatdec.c.

Referenced by concat_read_header().

static int concat_read_header ( AVFormatContext avf)
static

Definition at line 151 of file concatdec.c.

static int open_next_file ( AVFormatContext avf)
static

Definition at line 244 of file concatdec.c.

Referenced by concat_read_packet().

static int concat_read_packet ( AVFormatContext avf,
AVPacket pkt 
)
static

Definition at line 258 of file concatdec.c.

Variable Documentation

const AVOption options[]
static
Initial value:
= {
{ "safe", "enable safe mode",
OFFSET(safe), AV_OPT_TYPE_INT, {.i64 = -1}, -1, 1, DEC },
{ NULL }
}

Definition at line 282 of file concatdec.c.

const AVClass concat_class
static
Initial value:
= {
.class_name = "concat demuxer",
.item_name = av_default_item_name,
.option = options,
}

Definition at line 288 of file concatdec.c.

Referenced by init().

AVInputFormat ff_concat_demuxer
Initial value:
= {
.name = "concat",
.long_name = NULL_IF_CONFIG_SMALL("Virtual concatenation script"),
.priv_data_size = sizeof(ConcatContext),
.priv_class = &concat_class,
}

Definition at line 296 of file concatdec.c.