diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2015-04-01 21:27:45 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2015-04-01 21:34:20 +0200 |
commit | 53bf6b155cee8cdf0fd12fe49e4ccfb9cf6714a2 (patch) | |
tree | 0247f1767a32acb9aa10785941245f2dc3fc5d3f /libavformat/rtspdec.c | |
parent | b99a8e4e4a1e2043819e0507371c7617462bb8e5 (diff) | |
parent | e3ec6fe7bb2a622a863e3912181717a659eb1bad (diff) |
Merge commit 'e3ec6fe7bb2a622a863e3912181717a659eb1bad'
* commit 'e3ec6fe7bb2a622a863e3912181717a659eb1bad':
rtsp: Add a buffer_size option
Conflicts:
libavformat/rtsp.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/rtspdec.c')
-rw-r--r-- | libavformat/rtspdec.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libavformat/rtspdec.c b/libavformat/rtspdec.c index 12aa122b4b..9ae6b0088c 100644 --- a/libavformat/rtspdec.c +++ b/libavformat/rtspdec.c @@ -287,10 +287,15 @@ static int rtsp_read_setup(AVFormatContext *s, char* host, char *controlurl) request.transports[0].interleaved_max); } else { do { + AVDictionary *opts = NULL; + char buf[256]; + snprintf(buf, sizeof(buf), "%d", rt->buffer_size); + av_dict_set(&opts, "buffer_size", buf, 0); ff_url_join(url, sizeof(url), "rtp", NULL, host, localport, NULL); av_dlog(s, "Opening: %s", url); ret = ffurl_open(&rtsp_st->rtp_handle, url, AVIO_FLAG_READ_WRITE, - &s->interrupt_callback, NULL); + &s->interrupt_callback, &opts); + av_dict_free(&opts); if (ret) localport += 2; } while (ret || localport > rt->rtp_port_max); |