FFmpeg
Data Structures | Macros | Functions | Variables
rpl.c File Reference
#include <inttypes.h>
#include <stdlib.h>
#include "libavutil/avstring.h"
#include "libavutil/dict.h"
#include "avformat.h"
#include "demux.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  RPLContext
 

Macros

#define RPL_SIGNATURE   "ARMovie\x0A"
 
#define RPL_SIGNATURE_SIZE   8
 
#define RPL_LINE_LENGTH   256
 256 is arbitrary, but should be big enough for any reasonable file. More...
 

Functions

static int rpl_probe (const AVProbeData *p)
 
static int read_line (AVIOContext *pb, char *line, int bufsize)
 
static int32_t read_int (const char *line, const char **endptr, int *error)
 
static int32_t read_line_and_int (AVIOContext *pb, int *error)
 
static AVRational read_fps (const char *line, int *error)
 Parsing for fps, which can be a fraction. More...
 
static int rpl_read_header (AVFormatContext *s)
 
static int rpl_read_packet (AVFormatContext *s, AVPacket *pkt)
 

Variables

const FFInputFormat ff_rpl_demuxer
 

Macro Definition Documentation

◆ RPL_SIGNATURE

#define RPL_SIGNATURE   "ARMovie\x0A"

Definition at line 31 of file rpl.c.

◆ RPL_SIGNATURE_SIZE

#define RPL_SIGNATURE_SIZE   8

Definition at line 32 of file rpl.c.

◆ RPL_LINE_LENGTH

#define RPL_LINE_LENGTH   256

256 is arbitrary, but should be big enough for any reasonable file.

Definition at line 35 of file rpl.c.

Function Documentation

◆ rpl_probe()

static int rpl_probe ( const AVProbeData p)
static

Definition at line 37 of file rpl.c.

◆ read_line()

static int read_line ( AVIOContext pb,
char *  line,
int  bufsize 
)
static

Definition at line 55 of file rpl.c.

Referenced by read_line_and_int(), and rpl_read_header().

◆ read_int()

static int32_t read_int ( const char *  line,
const char **  endptr,
int *  error 
)
static

Definition at line 72 of file rpl.c.

Referenced by read_fps(), read_line_and_int(), and rpl_read_header().

◆ read_line_and_int()

static int32_t read_line_and_int ( AVIOContext pb,
int *  error 
)
static

Definition at line 84 of file rpl.c.

Referenced by rpl_read_header().

◆ read_fps()

static AVRational read_fps ( const char *  line,
int *  error 
)
static

Parsing for fps, which can be a fraction.

Unfortunately, the spec for the header leaves out a lot of details, so this is mostly guessing.

Definition at line 96 of file rpl.c.

Referenced by rpl_read_header().

◆ rpl_read_header()

static int rpl_read_header ( AVFormatContext s)
static

Definition at line 116 of file rpl.c.

◆ rpl_read_packet()

static int rpl_read_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 321 of file rpl.c.

Variable Documentation

◆ ff_rpl_demuxer

const FFInputFormat ff_rpl_demuxer
Initial value:
= {
.p.name = "rpl",
.p.long_name = NULL_IF_CONFIG_SMALL("RPL / ARMovie"),
.priv_data_size = sizeof(RPLContext),
}

Definition at line 403 of file rpl.c.

RPLContext
Definition: rpl.c:45
read_packet
static int read_packet(void *opaque, uint8_t *buf, int buf_size)
Definition: avio_read_callback.c:42
read_header
static int read_header(FFV1Context *f)
Definition: ffv1dec.c:540
rpl_read_header
static int rpl_read_header(AVFormatContext *s)
Definition: rpl.c:116
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:94
rpl_probe
static int rpl_probe(const AVProbeData *p)
Definition: rpl.c:37
read_probe
static int read_probe(const AVProbeData *p)
Definition: cdg.c:30
rpl_read_packet
static int rpl_read_packet(AVFormatContext *s, AVPacket *pkt)
Definition: rpl.c:321