Libav
rdt.h
Go to the documentation of this file.
1 /*
2  * Realmedia RTSP (RDT) definitions
3  * Copyright (c) 2007 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
4  *
5  * This file is part of Libav.
6  *
7  * Libav is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU Lesser General Public
9  * License as published by the Free Software Foundation; either
10  * version 2.1 of the License, or (at your option) any later version.
11  *
12  * Libav is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  * Lesser General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public
18  * License along with Libav; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20  */
21 
22 #ifndef AVFORMAT_RDT_H
23 #define AVFORMAT_RDT_H
24 
25 #include <stdint.h>
26 #include "avformat.h"
27 #include "rtpdec.h"
28 
29 typedef struct RDTDemuxContext RDTDemuxContext;
30 
42  int first_stream_of_set_idx,
43  void *priv_data,
44  RTPDynamicProtocolHandler *handler);
46 
59 void ff_rdt_calc_response_and_checksum(char response[41], char chksum[9],
60  const char *challenge);
61 
66 
75 void ff_rdt_subscribe_rule(char *cmd, int size,
76  int stream_nr, int rule_nr);
77 
90 int ff_rdt_parse_header(const uint8_t *buf, int len,
91  int *pset_id, int *pseq_no, int *pstream_id,
92  int *pis_keyframe, uint32_t *ptimestamp);
93 
99  uint8_t **buf, int len);
100 
109 void ff_real_parse_sdp_a_line(AVFormatContext *s, int stream_index,
110  const char *buf);
111 
112 #endif /* AVFORMAT_RDT_H */
void ff_real_parse_sdp_a_line(AVFormatContext *s, int stream_index, const char *buf)
Parse a server-related SDP line.
Definition: rdt.c:513
RDTDemuxContext * ff_rdt_parse_open(AVFormatContext *ic, int first_stream_of_set_idx, void *priv_data, RTPDynamicProtocolHandler *handler)
Allocate and init the RDT parsing context.
Definition: rdt.c:55
int size
Format I/O context.
Definition: avformat.h:922
uint8_t
void ff_rdt_calc_response_and_checksum(char response[41], char chksum[9], const char *challenge)
Calculate the response (RealChallenge2 in the RTSP header) to the challenge (RealChallenge1 in the RT...
Definition: rdt.c:94
AVFormatContext * ic
the containing (RTSP) demux context
Definition: rdt.c:40
int ff_rdt_parse_packet(RDTDemuxContext *s, AVPacket *pkt, uint8_t **buf, int len)
Parse RDT-style packet data (header + media data).
Definition: rdt.c:335
int ff_rdt_parse_header(const uint8_t *buf, int len, int *pset_id, int *pseq_no, int *pstream_id, int *pis_keyframe, uint32_t *ptimestamp)
Parse RDT-style packet header.
Definition: rdt.c:190
void ff_rdt_subscribe_rule(char *cmd, int size, int stream_nr, int rule_nr)
Add subscription information to Subscribe parameter string.
Definition: rdt.c:384
Main libavformat public API header.
void ff_register_rdt_dynamic_payload_handlers(void)
Register RDT-related dynamic payload handlers with our cache.
Definition: rdt.c:571
int len
void ff_rdt_parse_close(RDTDemuxContext *s)
Definition: rdt.c:78
This structure stores compressed data.
Definition: avcodec.h:950