libavformat/file.c File Reference
#include "libavutil/avstring.h"
#include "libavutil/opt.h"
#include "avformat.h"
#include <fcntl.h>
#include <sys/stat.h>
#include <stdlib.h>
#include "os_support.h"
#include "url.h"
Include dependency graph for libavformat/file.c:

Go to the source code of this file.

Data Structures

struct  FileContext
 

Macros

#define S_ISFIFO(m)   0
 

Typedefs

typedef struct FileContext FileContext
 

Functions

static int file_read (URLContext *h, unsigned char *buf, int size)
 
static int file_write (URLContext *h, const unsigned char *buf, int size)
 
static int file_get_handle (URLContext *h)
 
static int file_check (URLContext *h, int mask)
 

Variables

static const AVOption file_options []
 
static const AVClass file_class
 

Macro Definition Documentation

#define S_ISFIFO (   m)    0

Definition at line 42 of file libavformat/file.c.

Referenced by file_check().

Typedef Documentation

typedef struct FileContext FileContext

Function Documentation

static int file_check ( URLContext h,
int  mask 
)
static

Definition at line 86 of file libavformat/file.c.

static int file_get_handle ( URLContext h)
static

Definition at line 80 of file libavformat/file.c.

Referenced by file_check().

static int file_read ( URLContext h,
unsigned char *  buf,
int  size 
)
static

Definition at line 66 of file libavformat/file.c.

Referenced by file_check().

static int file_write ( URLContext h,
const unsigned char *  buf,
int  size 
)
static

Definition at line 73 of file libavformat/file.c.

Referenced by file_check().

Variable Documentation

const AVClass file_class
static
Initial value:
= {
.class_name = "file",
.item_name = av_default_item_name,
.option = file_options,
}
av_default_item_name
LIBAVUTIL_VERSION_INT
Definition: eval.c:55
static const AVOption file_options[]

Definition at line 59 of file libavformat/file.c.

const AVOption file_options[]
static
Initial value:
= {
{ "truncate", "Truncate existing files on write", offsetof(FileContext, trunc), AV_OPT_TYPE_INT, { .i64 = 1 }, 0, 1, AV_OPT_FLAG_ENCODING_PARAM },
{ NULL }
}
#define AV_OPT_FLAG_ENCODING_PARAM
a generic parameter which can be set by the user for muxing or encoding
Definition: opt.h:281
static av_always_inline av_const double trunc(double x)
Definition: libm.h:176
NULL
Definition: eval.c:55

Definition at line 54 of file libavformat/file.c.