diff options
author | Ronald S. Bultje <rsbultje@gmail.com> | 2008-09-07 01:22:18 +0000 |
---|---|---|
committer | Ronald S. Bultje <rsbultje@gmail.com> | 2008-09-07 01:22:18 +0000 |
commit | 1256d16b6cf937c180bb898a37e1c79a27b79922 (patch) | |
tree | 6303fbea6e991249fd3a6a58041b27bab5bbe2f5 /libavformat/rdt.c | |
parent | ff13ba92fd6bfee75db3d1e2f593474946cbfb68 (diff) | |
download | ffmpeg-1256d16b6cf937c180bb898a37e1c79a27b79922.tar.gz |
Implement a RDT-specific SET_PARAMETER command that subscribes to the
first stream in a RTSP/RDT session. See discussion in "Realmedia patch"
thread on ML.
Originally committed as revision 15235 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/rdt.c')
-rw-r--r-- | libavformat/rdt.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/libavformat/rdt.c b/libavformat/rdt.c index e5a1f89c6d..6ed0f19417 100644 --- a/libavformat/rdt.c +++ b/libavformat/rdt.c @@ -134,6 +134,18 @@ rdt_load_mdpr (rdt_data *rdt, AVStream *st, int rule_nr) return 0; } +void +ff_rdt_subscribe_rule (RTPDemuxContext *s, char *cmd, int size, + int stream_nr, int rule_nr) +{ + rdt_data *rdt = s->dynamic_protocol_context; + + av_strlcatf(cmd, size, "stream=%d;rule=%d,stream=%d;rule=%d", + stream_nr, rule_nr, stream_nr, rule_nr + 1); + + rdt_load_mdpr(rdt, s->st, 0); +} + static unsigned char * rdt_parse_b64buf (unsigned int *target_len, const char *p) { @@ -157,7 +169,6 @@ rdt_parse_sdp_line (AVStream *stream, void *d, const char *line) if (av_strstart(p, "OpaqueData:buffer;", &p)) { rdt->mlti_data = rdt_parse_b64buf(&rdt->mlti_data_size, p); - rdt_load_mdpr(rdt, stream, 0); } else if (av_strstart(p, "StartTime:integer;", &p)) stream->first_dts = atoi(p); |