aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2011-12-30 11:38:05 +0200
committerMartin Storsjö <martin@martin.st>2012-01-05 23:56:52 +0200
commit32b83aeec1a129d6eef2e89c7f107c614dfb4574 (patch)
tree564aa1bbac6df55321d56f46f048144c7ad5ffa1 /libavformat
parentbb5b3940b08d8dad5b7e948e8f3b02cd2eb70716 (diff)
downloadffmpeg-32b83aeec1a129d6eef2e89c7f107c614dfb4574.tar.gz
avio: Add an URLProtocol flag for indicating that a protocol uses network
This definition is in two files, since the definitions will move to the private header at the next bump. Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/avio.h1
-rw-r--r--libavformat/gopher.c1
-rw-r--r--libavformat/http.c3
-rw-r--r--libavformat/librtmp.c5
-rw-r--r--libavformat/mmsh.c1
-rw-r--r--libavformat/mmst.c1
-rw-r--r--libavformat/rtmpproto.c1
-rw-r--r--libavformat/rtpproto.c1
-rw-r--r--libavformat/tcp.c1
-rw-r--r--libavformat/tls.c1
-rw-r--r--libavformat/udp.c1
-rw-r--r--libavformat/url.h1
12 files changed, 18 insertions, 0 deletions
diff --git a/libavformat/avio.h b/libavformat/avio.h
index dec2a5effe..e73264f4aa 100644
--- a/libavformat/avio.h
+++ b/libavformat/avio.h
@@ -146,6 +146,7 @@ typedef struct URLContext {
} URLContext;
#define URL_PROTOCOL_FLAG_NESTED_SCHEME 1 /*< The protocol name can be the first part of a nested protocol scheme */
+#define URL_PROTOCOL_FLAG_NETWORK 2 /*< The protocol uses network */
/**
* @deprecated This struct is to be made private. Use the higher-level
diff --git a/libavformat/gopher.c b/libavformat/gopher.c
index c0338619b3..a149f7fd6b 100644
--- a/libavformat/gopher.c
+++ b/libavformat/gopher.c
@@ -121,4 +121,5 @@ URLProtocol ff_gopher_protocol = {
.url_write = gopher_write,
.url_close = gopher_close,
.priv_data_size = sizeof(GopherContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/http.c b/libavformat/http.c
index 7badf720ed..eea8dedcbc 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -565,6 +565,7 @@ URLProtocol ff_http_protocol = {
.url_get_file_handle = http_get_file_handle,
.priv_data_size = sizeof(HTTPContext),
.priv_data_class = &http_context_class,
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
#endif
#if CONFIG_HTTPS_PROTOCOL
@@ -578,6 +579,7 @@ URLProtocol ff_https_protocol = {
.url_get_file_handle = http_get_file_handle,
.priv_data_size = sizeof(HTTPContext),
.priv_data_class = &https_context_class,
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
#endif
@@ -693,5 +695,6 @@ URLProtocol ff_httpproxy_protocol = {
.url_close = http_proxy_close,
.url_get_file_handle = http_get_file_handle,
.priv_data_size = sizeof(HTTPContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
#endif
diff --git a/libavformat/librtmp.c b/libavformat/librtmp.c
index c04c833c01..2d028b05e2 100644
--- a/libavformat/librtmp.c
+++ b/libavformat/librtmp.c
@@ -162,6 +162,7 @@ URLProtocol ff_rtmp_protocol = {
.url_read_seek = rtmp_read_seek,
.url_get_file_handle = rtmp_get_file_handle,
.priv_data_size = sizeof(RTMP),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
URLProtocol ff_rtmpt_protocol = {
@@ -174,6 +175,7 @@ URLProtocol ff_rtmpt_protocol = {
.url_read_seek = rtmp_read_seek,
.url_get_file_handle = rtmp_get_file_handle,
.priv_data_size = sizeof(RTMP),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
URLProtocol ff_rtmpe_protocol = {
@@ -186,6 +188,7 @@ URLProtocol ff_rtmpe_protocol = {
.url_read_seek = rtmp_read_seek,
.url_get_file_handle = rtmp_get_file_handle,
.priv_data_size = sizeof(RTMP),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
URLProtocol ff_rtmpte_protocol = {
@@ -198,6 +201,7 @@ URLProtocol ff_rtmpte_protocol = {
.url_read_seek = rtmp_read_seek,
.url_get_file_handle = rtmp_get_file_handle,
.priv_data_size = sizeof(RTMP),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
URLProtocol ff_rtmps_protocol = {
@@ -210,4 +214,5 @@ URLProtocol ff_rtmps_protocol = {
.url_read_seek = rtmp_read_seek,
.url_get_file_handle = rtmp_get_file_handle,
.priv_data_size = sizeof(RTMP),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/mmsh.c b/libavformat/mmsh.c
index fa1a467223..5e9d0bc134 100644
--- a/libavformat/mmsh.c
+++ b/libavformat/mmsh.c
@@ -364,4 +364,5 @@ URLProtocol ff_mmsh_protocol = {
.url_read = mmsh_read,
.url_close = mmsh_close,
.priv_data_size = sizeof(MMSHContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/mmst.c b/libavformat/mmst.c
index fe21a32357..93ad073869 100644
--- a/libavformat/mmst.c
+++ b/libavformat/mmst.c
@@ -625,4 +625,5 @@ URLProtocol ff_mmst_protocol = {
.url_read = mms_read,
.url_close = mms_close,
.priv_data_size = sizeof(MMSTContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c
index 53d912e3c6..867969a670 100644
--- a/libavformat/rtmpproto.c
+++ b/libavformat/rtmpproto.c
@@ -1000,4 +1000,5 @@ URLProtocol ff_rtmp_protocol = {
.url_write = rtmp_write,
.url_close = rtmp_close,
.priv_data_size = sizeof(RTMPContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/rtpproto.c b/libavformat/rtpproto.c
index 93cad3c8e6..03794ae1ce 100644
--- a/libavformat/rtpproto.c
+++ b/libavformat/rtpproto.c
@@ -330,4 +330,5 @@ URLProtocol ff_rtp_protocol = {
.url_close = rtp_close,
.url_get_file_handle = rtp_get_file_handle,
.priv_data_size = sizeof(RTPContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/tcp.c b/libavformat/tcp.c
index 0d3aeaf48c..fdb457e8c5 100644
--- a/libavformat/tcp.c
+++ b/libavformat/tcp.c
@@ -204,4 +204,5 @@ URLProtocol ff_tcp_protocol = {
.url_close = tcp_close,
.url_get_file_handle = tcp_get_file_handle,
.priv_data_size = sizeof(TCPContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/tls.c b/libavformat/tls.c
index 26f5ee5106..fb84fa82b6 100644
--- a/libavformat/tls.c
+++ b/libavformat/tls.c
@@ -248,4 +248,5 @@ URLProtocol ff_tls_protocol = {
.url_write = tls_write,
.url_close = tls_close,
.priv_data_size = sizeof(TLSContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/udp.c b/libavformat/udp.c
index 2bdd3dc773..8bb63c6298 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -491,4 +491,5 @@ URLProtocol ff_udp_protocol = {
.url_close = udp_close,
.url_get_file_handle = udp_get_file_handle,
.priv_data_size = sizeof(UDPContext),
+ .flags = URL_PROTOCOL_FLAG_NETWORK,
};
diff --git a/libavformat/url.h b/libavformat/url.h
index ea8c7abb8f..14832af79b 100644
--- a/libavformat/url.h
+++ b/libavformat/url.h
@@ -33,6 +33,7 @@
#if !FF_API_OLD_AVIO
#define URL_PROTOCOL_FLAG_NESTED_SCHEME 1 /*< The protocol name can be the first part of a nested protocol scheme */
+#define URL_PROTOCOL_FLAG_NETWORK 2 /*< The protocol uses network */
extern int (*url_interrupt_cb)(void);