Logo Search packages:      
Sourcecode: blender version File versions

utils.c File Reference


Detailed Description

Various utility functions for using ffmpeg library.

Definition in file utils.c.

#include "avformat.h"
#include <assert.h>

Go to the source code of this file.

Classes

struct  AbvEntry

Defines

#define DEBUG_SEEK
#define DURATION_MAX_READ_SIZE   250000
#define MAX_READ_SIZE   5000000
#define MAX_STREAM_DURATION   ((int)(AV_TIME_BASE * 2.0))
#define PROBE_BUF_MAX   131072
#define PROBE_BUF_MIN   2048

Functions

int av_add_index_entry (AVStream *st, int64_t pos, int64_t timestamp, int size, int distance, int flags)
AVFormatContext * av_alloc_format_context (void)
static void av_build_index_raw (AVFormatContext *s)
void av_close_input_file (AVFormatContext *s)
void av_destruct_packet (AVPacket *pkt)
void av_destruct_packet_nofree (AVPacket *pkt)
int av_dup_packet (AVPacket *pkt)
static void av_estimate_timings (AVFormatContext *ic)
static void av_estimate_timings_from_bit_rate (AVFormatContext *ic)
static void av_estimate_timings_from_pts (AVFormatContext *ic)
int av_find_default_stream_index (AVFormatContext *s)
AVInputFormat * av_find_input_format (const char *short_name)
int av_find_stream_info (AVFormatContext *ic)
void av_frac_add (AVFrac *f, int64_t incr)
void av_frac_init (AVFrac *f, int64_t val, int64_t num, int64_t den)
void av_frac_set (AVFrac *f, int64_t val)
int av_get_packet (ByteIOContext *s, AVPacket *pkt, int size)
enum CodecID av_guess_codec (AVOutputFormat *fmt, const char *short_name, const char *filename, const char *mime_type, enum CodecType type)
static int av_has_timings (AVFormatContext *ic)
void av_hex_dump (FILE *f, uint8_t *buf, int size)
int av_index_search_timestamp (AVStream *st, int64_t wanted_timestamp, int flags)
static int av_interleave_packet (AVFormatContext *s, AVPacket *out, AVPacket *in, int flush)
static int av_interleave_packet_per_dts (AVFormatContext *s, AVPacket *out, AVPacket *pkt, int flush)
int av_interleaved_write_frame (AVFormatContext *s, AVPacket *pkt)
int av_new_packet (AVPacket *pkt, int size)
AVStream * av_new_stream (AVFormatContext *s, int id)
int av_open_input_file (AVFormatContext **ic_ptr, const char *filename, AVInputFormat *fmt, int buf_size, AVFormatParameters *ap)
int av_open_input_stream (AVFormatContext **ic_ptr, ByteIOContext *pb, const char *filename, AVInputFormat *fmt, AVFormatParameters *ap)
void av_pkt_dump (FILE *f, AVPacket *pkt, int dump_payload)
AVImageFormat * av_probe_image_format (AVProbeData *pd)
AVInputFormat * av_probe_input_format (AVProbeData *pd, int is_opened)
int av_read_frame (AVFormatContext *s, AVPacket *pkt)
static void av_read_frame_flush (AVFormatContext *s)
static int av_read_frame_internal (AVFormatContext *s, AVPacket *pkt)
int av_read_image (ByteIOContext *pb, const char *filename, AVImageFormat *fmt, int(*alloc_cb)(void *, AVImageInfo *info), void *opaque)
int av_read_packet (AVFormatContext *s, AVPacket *pkt)
int av_read_pause (AVFormatContext *s)
int av_read_play (AVFormatContext *s)
void av_register_image_format (AVImageFormat *img_fmt)
void av_register_input_format (AVInputFormat *format)
void av_register_output_format (AVOutputFormat *format)
int av_seek_frame (AVFormatContext *s, int stream_index, int64_t timestamp, int flags)
int av_seek_frame_binary (AVFormatContext *s, int stream_index, int64_t target_ts, int flags)
static int av_seek_frame_byte (AVFormatContext *s, int stream_index, int64_t pos, int flags)
static int av_seek_frame_generic (AVFormatContext *s, int stream_index, int64_t timestamp, int flags)
int av_set_parameters (AVFormatContext *s, AVFormatParameters *ap)
void av_set_pts_info (AVStream *s, int pts_wrap_bits, int pts_num, int pts_den)
static void av_update_cur_dts (AVFormatContext *s, AVStream *ref_st, int64_t timestamp)
static void av_update_stream_timings (AVFormatContext *ic)
int av_write_frame (AVFormatContext *s, AVPacket *pkt)
int av_write_header (AVFormatContext *s)
int av_write_image (ByteIOContext *pb, AVImageFormat *fmt, AVImageInfo *img)
int av_write_trailer (AVFormatContext *s)
 Write the stream trailer to an output media file and free the file private data.
static void compute_frame_duration (int *pnum, int *pden, AVStream *st, AVCodecParserContext *pc, AVPacket *pkt)
static void compute_pkt_fields (AVFormatContext *s, AVStream *st, AVCodecParserContext *pc, AVPacket *pkt)
static int compute_pkt_fields2 (AVStream *st, AVPacket *pkt)
void dump_format (AVFormatContext *ic, int index, const char *url, int is_output)
void fifo_free (FifoBuffer *f)
int fifo_init (FifoBuffer *f, int size)
int fifo_read (FifoBuffer *f, uint8_t *buf, int buf_size, uint8_t **rptr_ptr)
void fifo_realloc (FifoBuffer *f, unsigned int new_size)
int fifo_size (FifoBuffer *f, uint8_t *rptr)
void fifo_write (FifoBuffer *f, uint8_t *buf, int size, uint8_t **wptr_ptr)
int filename_number_test (const char *filename)
static void fill_all_stream_timings (AVFormatContext *ic)
int find_info_tag (char *arg, int arg_size, const char *tag1, const char *info)
static void flush_packet_queue (AVFormatContext *s)
static const char * format_to_name (void *ptr)
static int get_audio_frame_size (AVCodecContext *enc, int size)
int get_frame_filename (char *buf, int buf_size, const char *path, int number)
AVOutputFormat * guess_format (const char *short_name, const char *filename, const char *mime_type)
AVImageFormat * guess_image_format (const char *filename)
AVOutputFormat * guess_stream_format (const char *short_name, const char *filename, const char *mime_type)
static int has_codec_parameters (AVCodecContext *enc)
static int is_intra_only (AVCodecContext *enc)
static int is_raw_stream (AVFormatContext *s)
static int64_t lsb2full (int64_t lsb, int64_t last_ts, int lsb_bits)
int match_ext (const char *filename, const char *extensions)
int64_t parse_date (const char *datestr, int duration)
int parse_frame_rate (int *frame_rate, int *frame_rate_base, const char *arg)
int parse_image_size (int *width_ptr, int *height_ptr, const char *str)
int put_fifo (ByteIOContext *pb, FifoBuffer *f, int buf_size, uint8_t **rptr_ptr)
static void truncate_ts (AVStream *st, AVPacket *pkt)
static int try_decode_frame (AVStream *st, const uint8_t *data, int size)
void url_split (char *proto, int proto_size, char *authorization, int authorization_size, char *hostname, int hostname_size, int *port_ptr, char *path, int path_size, const char *url)

Variables

static const AVClass av_format_context_class = { "AVFormatContext", format_to_name }
AVInputFormat * first_iformat = NULL
AVImageFormat * first_image_format = NULL
AVOutputFormat * first_oformat = NULL
static AbvEntry frame_abvs []


Generated by  Doxygen 1.6.0   Back to index