Commit 40db590e authored by Wim Taymans's avatar Wim Taymans
Browse files

RTSP: parse rtsph uris as RTSP tunneled over HTTP

Add transport define for RTSP tunneled over HTTP.

Parse rtsph:// uris as tunneled HTTP over TCP.

API: GstRTSPLowerTrans::GST_RTSP_LOWER_TRANS_HTTP

See also #573173.
parent b7c53b78
......@@ -81,6 +81,7 @@ typedef enum {
* @GST_RTSP_LOWER_TRANS_UDP: stream data over UDP
* @GST_RTSP_LOWER_TRANS_UDP_MCAST: stream data over UDP multicast
* @GST_RTSP_LOWER_TRANS_TCP: stream data over TCP
* @GST_RTSP_LOWER_TRANS_HTTP: stream data tunneled over HTTP. Since: 0.10.23
*
* The different transport methods.
*/
......@@ -88,7 +89,8 @@ typedef enum {
GST_RTSP_LOWER_TRANS_UNKNOWN = 0,
GST_RTSP_LOWER_TRANS_UDP = (1 << 0),
GST_RTSP_LOWER_TRANS_UDP_MCAST = (1 << 1),
GST_RTSP_LOWER_TRANS_TCP = (1 << 2)
GST_RTSP_LOWER_TRANS_TCP = (1 << 2),
GST_RTSP_LOWER_TRANS_HTTP = (1 << 4)
} GstRTSPLowerTrans;
/**
......
......@@ -82,6 +82,8 @@ gst_rtsp_url_get_type (void)
#define RTSPU_PROTO_LEN 8
#define RTSPT_PROTO "rtspt://"
#define RTSPT_PROTO_LEN 8
#define RTSPH_PROTO "rtsph://"
#define RTSPH_PROTO_LEN 8
/* format is rtsp[u]://[user:passwd@]host[:port]/abspath[?query] */
......@@ -118,6 +120,9 @@ gst_rtsp_url_parse (const gchar * urlstr, GstRTSPUrl ** url)
} else if (g_str_has_prefix (p, RTSPT_PROTO)) {
res->transports = GST_RTSP_LOWER_TRANS_TCP;
p += RTSPT_PROTO_LEN;
} else if (g_str_has_prefix (p, RTSPH_PROTO)) {
res->transports = GST_RTSP_LOWER_TRANS_HTTP | GST_RTSP_LOWER_TRANS_TCP;
p += RTSPH_PROTO_LEN;
} else
goto invalid;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment