libavformat/flvdec.c File Reference

#include "libavutil/avstring.h"
#include "libavutil/dict.h"
#include "libavutil/opt.h"
#include "libavutil/intfloat.h"
#include "libavutil/mathematics.h"
#include "libavcodec/bytestream.h"
#include "libavcodec/mpeg4audio.h"
#include "avformat.h"
#include "internal.h"
#include "avio_internal.h"
#include "flv.h"

Go to the source code of this file.

Data Structures

struct  FLVContext

Defines

#define VALIDATE_INDEX_TS_THRESH   2500
#define OFFSET(x)   offsetof(FLVContext, x)
#define VD   AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_DECODING_PARAM

Functions

static int flv_probe (AVProbeData *p)
static AVStreamcreate_stream (AVFormatContext *s, int codec_type)
static int flv_same_audio_codec (AVCodecContext *acodec, int flags)
static void flv_set_audio_codec (AVFormatContext *s, AVStream *astream, AVCodecContext *acodec, int flv_codecid)
static int flv_same_video_codec (AVCodecContext *vcodec, int flags)
static int flv_set_video_codec (AVFormatContext *s, AVStream *vstream, int flv_codecid)
static int amf_get_string (AVIOContext *ioc, char *buffer, int buffsize)
static int parse_keyframes_index (AVFormatContext *s, AVIOContext *ioc, AVStream *vstream, int64_t max_pos)
static int amf_parse_object (AVFormatContext *s, AVStream *astream, AVStream *vstream, const char *key, int64_t max_pos, int depth)
static int flv_read_metabody (AVFormatContext *s, int64_t next_pos)
static int flv_read_header (AVFormatContext *s)
static int flv_read_close (AVFormatContext *s)
static int flv_get_extradata (AVFormatContext *s, AVStream *st, int size)
static int flv_queue_extradata (FLVContext *flv, AVIOContext *pb, int stream, int size)
static void clear_index_entries (AVFormatContext *s, int64_t pos)
static int flv_data_packet (AVFormatContext *s, AVPacket *pkt, int64_t dts, int64_t next)
static int flv_read_packet (AVFormatContext *s, AVPacket *pkt)
static int flv_read_seek (AVFormatContext *s, int stream_index, int64_t ts, int flags)

Variables

static const AVOption options []
class {
      class_name = "flvdec"
      item_name = av_default_item_name
      option = options
      version = LIBAVUTIL_VERSION_INT
}; 
AVInputFormat ff_flv_demuxer


Define Documentation

#define OFFSET (  )     offsetof(FLVContext, x)

Definition at line 886 of file flvdec.c.

#define VALIDATE_INDEX_TS_THRESH   2500

Definition at line 39 of file flvdec.c.

Referenced by flv_read_packet().

#define VD   AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_DECODING_PARAM

Definition at line 887 of file flvdec.c.


Function Documentation

static int amf_get_string ( AVIOContext ioc,
char *  buffer,
int  buffsize 
) [static]

static int amf_parse_object ( AVFormatContext s,
AVStream astream,
AVStream vstream,
const char *  key,
int64_t  max_pos,
int  depth 
) [static]

Definition at line 324 of file flvdec.c.

Referenced by flv_read_metabody().

static void clear_index_entries ( AVFormatContext s,
int64_t  pos 
) [static]

Definition at line 561 of file flvdec.c.

Referenced by flv_read_packet().

static AVStream* create_stream ( AVFormatContext s,
int  codec_type 
) [static]

Definition at line 69 of file flvdec.c.

Referenced by amf_parse_object(), flv_data_packet(), flv_read_header(), and flv_read_packet().

static int flv_data_packet ( AVFormatContext s,
AVPacket pkt,
int64_t  dts,
int64_t  next 
) [static]

Definition at line 578 of file flvdec.c.

static int flv_get_extradata ( AVFormatContext s,
AVStream st,
int  size 
) [static]

Definition at line 538 of file flvdec.c.

Referenced by flv_read_packet().

static int flv_probe ( AVProbeData p  )  [static]

Definition at line 58 of file flvdec.c.

static int flv_queue_extradata ( FLVContext flv,
AVIOContext pb,
int  stream,
int  size 
) [static]

Definition at line 549 of file flvdec.c.

Referenced by flv_read_packet().

static int flv_read_close ( AVFormatContext s  )  [static]

Definition at line 529 of file flvdec.c.

static int flv_read_header ( AVFormatContext s  )  [static]

Definition at line 494 of file flvdec.c.

static int flv_read_metabody ( AVFormatContext s,
int64_t  next_pos 
) [static]

Definition at line 457 of file flvdec.c.

Referenced by flv_read_packet().

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

Definition at line 636 of file flvdec.c.

static int flv_read_seek ( AVFormatContext s,
int  stream_index,
int64_t  ts,
int  flags 
) [static]

Definition at line 878 of file flvdec.c.

static int flv_same_audio_codec ( AVCodecContext acodec,
int  flags 
) [static]

Definition at line 83 of file flvdec.c.

Referenced by flv_read_packet().

static int flv_same_video_codec ( AVCodecContext vcodec,
int  flags 
) [static]

Definition at line 176 of file flvdec.c.

Referenced by flv_read_packet().

static void flv_set_audio_codec ( AVFormatContext s,
AVStream astream,
AVCodecContext acodec,
int  flv_codecid 
) [static]

Definition at line 131 of file flvdec.c.

Referenced by amf_parse_object(), and flv_read_packet().

static int flv_set_video_codec ( AVFormatContext s,
AVStream vstream,
int  flv_codecid 
) [static]

Definition at line 201 of file flvdec.c.

Referenced by amf_parse_object(), and flv_read_packet().

static int parse_keyframes_index ( AVFormatContext s,
AVIOContext ioc,
AVStream vstream,
int64_t  max_pos 
) [static]

Definition at line 246 of file flvdec.c.

Referenced by amf_parse_object().


Variable Documentation

const { ... } [static]

class_name = "flvdec"

Definition at line 894 of file flvdec.c.

Initial value:

 {
    .name           = "flv",
    .long_name      = NULL_IF_CONFIG_SMALL("FLV (Flash Video)"),
    .priv_data_size = sizeof(FLVContext),
    .read_probe     = flv_probe,
    .read_header    = flv_read_header,
    .read_packet    = flv_read_packet,
    .read_seek      = flv_read_seek,
    .read_close     = flv_read_close,
    .extensions     = "flv",
    .priv_class     = &class,
}

Definition at line 900 of file flvdec.c.

item_name = av_default_item_name

Definition at line 895 of file flvdec.c.

Definition at line 896 of file flvdec.c.

const AVOption options[] [static]

Initial value:

 {
    { "flv_metadata", "Allocate streams according the onMetaData array",      OFFSET(trust_metadata), AV_OPT_TYPE_INT,    { .i64 = 0 }, 0, 1, VD},
    { NULL }
}

Definition at line 888 of file flvdec.c.

Definition at line 897 of file flvdec.c.


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