libavformat/sdp.c File Reference

#include <string.h>
#include "libavutil/avstring.h"
#include "libavutil/base64.h"
#include "avformat.h"
#include "internal.h"
#include "avc.h"
#include "rtp.h"

Go to the source code of this file.


int avf_sdp_create (AVFormatContext *ac[], int n_files, char *buff, int size)
 Generates an SDP for an RTP session.
void ff_sdp_write_media (char *buff, int size, AVCodecContext *c, const char *dest_addr, int port, int ttl)
 Appends the media-specific SDP fragment for the media stream c to the buffer buff.

Function Documentation

int avf_sdp_create ( AVFormatContext ac[],
int  n_files,
char *  buff,
int  size 

Generates an SDP for an RTP session.

ac array of AVFormatContexts describing the RTP streams. If the array is composed by only one context, such context can contain multiple AVStreams (one AVStream per RTP stream). Otherwise, all the contexts in the array (an AVCodecContext per RTP stream) must contain only one AVStream.
n_files number of AVCodecContexts contained in ac
buff buffer where the SDP will be stored (must be allocated by the caller)
size the size of the buffer
0 if OK, AVERROR_xxx on error

Definition at line 368 of file sdp.c.

Referenced by prepare_sdp_description(), and print_sdp().

void ff_sdp_write_media ( char *  buff,
int  size,
AVCodecContext c,
const char *  dest_addr,
int  port,
int  ttl 

Appends the media-specific SDP fragment for the media stream c to the buffer buff.

Note, the buffer needs to be initialized, since it is appended to existing content.

buff the buffer to append the SDP fragment to
size the size of the buff buffer
c the AVCodecContext of the media to describe
dest_addr the destination address of the media stream, may be NULL
port the destination port of the media stream, 0 if unknown
ttl the time to live of the stream, 0 if not multicast

Definition at line 373 of file sdp.c.

Referenced by mov_write_udta_sdp().

Generated on Fri Oct 26 02:36:55 2012 for FFmpeg by  doxygen 1.5.8