FFmpeg
Functions | Variables
rtspenc.c File Reference
#include "avformat.h"
#include "mux.h"
#include "network.h"
#include "os_support.h"
#include "rtsp.h"
#include "internal.h"
#include "avio_internal.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/avstring.h"
#include "libavutil/time.h"
#include "url.h"

Go to the source code of this file.

Functions

int ff_rtsp_setup_output_streams (AVFormatContext *s, const char *addr)
 Announce the stream to the server and set up the RTSPStream child objects for each media stream. More...
 
static int rtsp_write_record (AVFormatContext *s)
 
static int rtsp_write_header (AVFormatContext *s)
 
int ff_rtsp_tcp_write_packet (AVFormatContext *s, RTSPStream *rtsp_st)
 Send buffered packets over TCP. More...
 
static int rtsp_write_packet (AVFormatContext *s, AVPacket *pkt)
 
static int rtsp_write_close (AVFormatContext *s)
 

Variables

static const AVClass rtsp_muxer_class
 
const AVOutputFormat ff_rtsp_muxer
 

Function Documentation

◆ ff_rtsp_setup_output_streams()

int ff_rtsp_setup_output_streams ( AVFormatContext s,
const char *  addr 
)

Announce the stream to the server and set up the RTSPStream child objects for each media stream.

Definition at line 46 of file rtspenc.c.

◆ rtsp_write_record()

static int rtsp_write_record ( AVFormatContext s)
static

Definition at line 111 of file rtspenc.c.

Referenced by rtsp_write_header().

◆ rtsp_write_header()

static int rtsp_write_header ( AVFormatContext s)
static

Definition at line 126 of file rtspenc.c.

◆ ff_rtsp_tcp_write_packet()

int ff_rtsp_tcp_write_packet ( AVFormatContext s,
RTSPStream rtsp_st 
)

Send buffered packets over TCP.

Definition at line 142 of file rtspenc.c.

Referenced by ff_rtsp_undo_setup(), and rtsp_write_packet().

◆ rtsp_write_packet()

static int rtsp_write_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 181 of file rtspenc.c.

◆ rtsp_write_close()

static int rtsp_write_close ( AVFormatContext s)
static

Definition at line 230 of file rtspenc.c.

Variable Documentation

◆ rtsp_muxer_class

const AVClass rtsp_muxer_class
static
Initial value:
= {
.class_name = "RTSP muxer",
.item_name = av_default_item_name,
.option = ff_rtsp_options,
}

Definition at line 39 of file rtspenc.c.

◆ ff_rtsp_muxer

const AVOutputFormat ff_rtsp_muxer
Initial value:
= {
.name = "rtsp",
.long_name = NULL_IF_CONFIG_SMALL("RTSP output"),
.priv_data_size = sizeof(RTSPState),
.audio_codec = AV_CODEC_ID_AAC,
.video_codec = AV_CODEC_ID_MPEG4,
.priv_class = &rtsp_muxer_class,
}

Definition at line 247 of file rtspenc.c.

rtsp_muxer_class
static const AVClass rtsp_muxer_class
Definition: rtspenc.c:39
AV_CODEC_ID_MPEG4
@ AV_CODEC_ID_MPEG4
Definition: codec_id.h:62
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
write_trailer
static int write_trailer(AVFormatContext *s1)
Definition: v4l2enc.c:100
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:237
rtsp_write_header
static int rtsp_write_header(AVFormatContext *s)
Definition: rtspenc.c:126
rtsp_write_close
static int rtsp_write_close(AVFormatContext *s)
Definition: rtspenc.c:230
AV_CODEC_ID_AAC
@ AV_CODEC_ID_AAC
Definition: codec_id.h:429
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:117
ff_rtsp_options
const AVOption ff_rtsp_options[]
Definition: rtsp.c:83
RTSPState
Private data for the RTSP demuxer.
Definition: rtsp.h:225
AVFMT_NOFILE
#define AVFMT_NOFILE
Demuxer will use avio_open, no opened file should be provided by the caller.
Definition: avformat.h:470
AVFMT_GLOBALHEADER
#define AVFMT_GLOBALHEADER
Format wants global header.
Definition: avformat.h:480
rtsp_write_packet
static int rtsp_write_packet(AVFormatContext *s, AVPacket *pkt)
Definition: rtspenc.c:181
flags
#define flags(name, subs,...)
Definition: cbs_av1.c:561
write_packet
static int write_packet(AVFormatContext *s1, AVPacket *pkt)
Definition: v4l2enc.c:92
write_header
static void write_header(FFV1Context *f)
Definition: ffv1enc.c:346