libavformat/segment.c File Reference

#include <strings.h>
#include <float.h>
#include "avformat.h"
#include "internal.h"
#include "libavutil/log.h"
#include "libavutil/opt.h"
#include "libavutil/avstring.h"
#include "libavutil/parseutils.h"
#include "libavutil/mathematics.h"

Go to the source code of this file.

Data Structures

struct  SegmentContext

Defines

#define OFFSET(x)   offsetof(SegmentContext, x)
#define E   AV_OPT_FLAG_ENCODING_PARAM

Functions

static int segment_start (AVFormatContext *s)
static int segment_end (AVFormatContext *oc)
static int seg_write_header (AVFormatContext *s)
static int seg_write_packet (AVFormatContext *s, AVPacket *pkt)
static int seg_write_trailer (struct AVFormatContext *s)

Variables

static const AVOption options []
static const AVClass seg_class
AVOutputFormat ff_segment_muxer


Define Documentation

#define E   AV_OPT_FLAG_ENCODING_PARAM

Definition at line 250 of file segment.c.

#define OFFSET (  )     offsetof(SegmentContext, x)

Definition at line 249 of file segment.c.


Function Documentation

static int seg_write_header ( AVFormatContext s  )  [static]

Definition at line 106 of file segment.c.

static int seg_write_packet ( AVFormatContext s,
AVPacket pkt 
) [static]

Definition at line 186 of file segment.c.

static int seg_write_trailer ( struct AVFormatContext s  )  [static]

Definition at line 236 of file segment.c.

static int segment_end ( AVFormatContext oc  )  [static]

Definition at line 91 of file segment.c.

Referenced by seg_write_packet(), and seg_write_trailer().

static int segment_start ( AVFormatContext s  )  [static]

Definition at line 49 of file segment.c.

Referenced by seg_write_packet().


Variable Documentation

Initial value:

 {
    .name           = "segment",
    .long_name      = NULL_IF_CONFIG_SMALL("segment muxer"),
    .priv_data_size = sizeof(SegmentContext),
    .flags          = AVFMT_GLOBALHEADER | AVFMT_NOFILE,
    .write_header   = seg_write_header,
    .write_packet   = seg_write_packet,
    .write_trailer  = seg_write_trailer,
    .priv_class     = &seg_class,
}

Definition at line 268 of file segment.c.

const AVOption options[] [static]

Initial value:

 {
    { "segment_format",    "container format used for the segments",  OFFSET(format),  AV_OPT_TYPE_STRING, {.str = NULL},  0, 0,       E },
    { "segment_time",      "segment length in seconds",               OFFSET(time),    AV_OPT_TYPE_FLOAT,  {.dbl = 2},     0, FLT_MAX, E },
    { "segment_list",      "output the segment list",                 OFFSET(list),    AV_OPT_TYPE_STRING, {.str = NULL},  0, 0,       E },
    { "segment_list_size", "maximum number of playlist entries",      OFFSET(size),    AV_OPT_TYPE_INT,    {.dbl = 5},     0, INT_MAX, E },
    { "segment_wrap",      "number after which the index wraps",      OFFSET(wrap),    AV_OPT_TYPE_INT,    {.dbl = 0},     0, INT_MAX, E },
    { NULL },
}

Definition at line 251 of file segment.c.

const AVClass seg_class [static]

Initial value:

 {
    .class_name = "segment muxer",
    .item_name  = av_default_item_name,
    .option     = options,
    .version    = LIBAVUTIL_VERSION_INT,
}

Definition at line 260 of file segment.c.


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