FFmpeg
Data Structures | Macros | Functions | Variables
rmenc.c File Reference
#include "avformat.h"
#include "avio_internal.h"
#include "mux.h"
#include "rm.h"
#include "libavutil/dict.h"

Go to the source code of this file.

Data Structures

struct  StreamInfo
 
struct  RMMuxContext
 

Macros

#define BUFFER_DURATION   0
 
#define MAX_HEADER_SIZE   (7 + 4 + 12)
 
#define MAX_PACKET_SIZE   (UINT16_MAX - MAX_HEADER_SIZE)
 

Functions

static void put_str (AVIOContext *s, const char *tag)
 
static void put_str8 (AVIOContext *s, const char *tag)
 
static int rv10_write_header (AVFormatContext *ctx, int data_size, int index_pos)
 
static void write_packet_header (AVFormatContext *ctx, StreamInfo *stream, int length, int key_frame)
 
static int rm_write_header (AVFormatContext *s)
 
static int rm_write_audio (AVFormatContext *s, const uint8_t *buf, int size, int flags)
 
static int rm_write_video (AVFormatContext *s, const uint8_t *buf, int size, int flags)
 
static int rm_write_packet (AVFormatContext *s, AVPacket *pkt)
 
static int rm_write_trailer (AVFormatContext *s)
 

Variables

const FFOutputFormat ff_rm_muxer
 

Macro Definition Documentation

◆ BUFFER_DURATION

#define BUFFER_DURATION   0

Definition at line 47 of file rmenc.c.

◆ MAX_HEADER_SIZE

#define MAX_HEADER_SIZE   (7 + 4 + 12)

Definition at line 49 of file rmenc.c.

◆ MAX_PACKET_SIZE

#define MAX_PACKET_SIZE   (UINT16_MAX - MAX_HEADER_SIZE)

Definition at line 51 of file rmenc.c.

Function Documentation

◆ put_str()

static void put_str ( AVIOContext s,
const char *  tag 
)
static

Definition at line 54 of file rmenc.c.

Referenced by rv10_write_header().

◆ put_str8()

static void put_str8 ( AVIOContext s,
const char *  tag 
)
static

Definition at line 62 of file rmenc.c.

Referenced by rv10_write_header().

◆ rv10_write_header()

static int rv10_write_header ( AVFormatContext ctx,
int  data_size,
int  index_pos 
)
static

Definition at line 70 of file rmenc.c.

Referenced by rm_write_header(), and rm_write_trailer().

◆ write_packet_header()

static void write_packet_header ( AVFormatContext ctx,
StreamInfo stream,
int  length,
int  key_frame 
)
static

Definition at line 294 of file rmenc.c.

Referenced by rm_write_audio(), and rm_write_video().

◆ rm_write_header()

static int rm_write_header ( AVFormatContext s)
static

Definition at line 314 of file rmenc.c.

◆ rm_write_audio()

static int rm_write_audio ( AVFormatContext s,
const uint8_t *  buf,
int  size,
int  flags 
)
static

Definition at line 367 of file rmenc.c.

Referenced by rm_write_packet().

◆ rm_write_video()

static int rm_write_video ( AVFormatContext s,
const uint8_t *  buf,
int  size,
int  flags 
)
static

Definition at line 389 of file rmenc.c.

Referenced by rm_write_packet().

◆ rm_write_packet()

static int rm_write_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 429 of file rmenc.c.

◆ rm_write_trailer()

static int rm_write_trailer ( AVFormatContext s)
static

Definition at line 438 of file rmenc.c.

Variable Documentation

◆ ff_rm_muxer

const FFOutputFormat ff_rm_muxer
Initial value:
= {
.p.name = "rm",
.p.long_name = NULL_IF_CONFIG_SMALL("RealMedia"),
.p.mime_type = "application/vnd.rn-realmedia",
.p.extensions = "rm,ra",
.priv_data_size = sizeof(RMMuxContext),
.p.audio_codec = AV_CODEC_ID_AC3,
.p.video_codec = AV_CODEC_ID_RV10,
.write_header = rm_write_header,
.write_packet = rm_write_packet,
.write_trailer = rm_write_trailer,
.p.codec_tag = (const AVCodecTag* const []){ ff_rm_codec_tags, 0 },
}

Definition at line 469 of file rmenc.c.

AV_CODEC_ID_AC3
@ AV_CODEC_ID_AC3
Definition: codec_id.h:449
rm_write_header
static int rm_write_header(AVFormatContext *s)
Definition: rmenc.c:314
AVCodecTag
Definition: internal.h:42
RMMuxContext
Definition: rmenc.c:40
rm_write_trailer
static int rm_write_trailer(AVFormatContext *s)
Definition: rmenc.c:438
ff_rm_codec_tags
const AVCodecTag ff_rm_codec_tags[]
Definition: rm.c:31
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
AV_CODEC_ID_RV10
@ AV_CODEC_ID_RV10
Definition: codec_id.h:57
rm_write_packet
static int rm_write_packet(AVFormatContext *s, AVPacket *pkt)
Definition: rmenc.c:429