diff options
author | Wim Taymans <wim.taymans@gmail.com> | 2006-10-18 16:18:55 +0000 |
---|---|---|
committer | Wim Taymans <wim.taymans@gmail.com> | 2006-10-18 16:18:55 +0000 |
commit | b14738fb2062a766ca772d894acfc08fa178882b (patch) | |
tree | e554a6b2de982920bbd7e598ba20c0faba94a63d /gst/rtsp/rtspurl.c | |
parent | 02ae90eaf49949ff9bb7ed398ab80bb7522f5460 (diff) |
gst/rtsp/: Reuse already existing enum for lower transport.
Original commit message from CVS:
* gst/rtsp/gstrtspsrc.c: (gst_rtsp_lower_trans_get_type),
(gst_rtspsrc_class_init), (gst_rtspsrc_loop_interleaved),
(gst_rtspsrc_loop_udp), (gst_rtspsrc_open),
(gst_rtspsrc_uri_get_protocols), (gst_rtspsrc_uri_set_uri):
* gst/rtsp/rtspconnection.c: (rtsp_connection_create):
* gst/rtsp/rtspdefs.h:
* gst/rtsp/rtspurl.c: (rtsp_url_parse):
* gst/rtsp/rtspurl.h:
Reuse already existing enum for lower transport.
Add rtspt and rtspu protocols.
Send redirect to rtspt when udp times out.
Diffstat (limited to 'gst/rtsp/rtspurl.c')
-rw-r--r-- | gst/rtsp/rtspurl.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/gst/rtsp/rtspurl.c b/gst/rtsp/rtspurl.c index cc11e91f..dd735565 100644 --- a/gst/rtsp/rtspurl.c +++ b/gst/rtsp/rtspurl.c @@ -49,6 +49,8 @@ #define RTSP_PROTO_LEN 7 #define RTSPU_PROTO "rtspu://" #define RTSPU_PROTO_LEN 8 +#define RTSPT_PROTO "rtspt://" +#define RTSPT_PROTO_LEN 8 /* format is rtsp[u]://[user:passwd@]host[:port]/abspath */ @@ -65,11 +67,16 @@ rtsp_url_parse (const gchar * urlstr, RTSPUrl ** url) p = (gchar *) urlstr; if (g_str_has_prefix (p, RTSP_PROTO)) { - res->protocol = RTSP_PROTO_TCP; + res->transports = + RTSP_LOWER_TRANS_TCP | RTSP_LOWER_TRANS_UDP | + RTSP_LOWER_TRANS_UDP_MCAST; p += RTSP_PROTO_LEN; } else if (g_str_has_prefix (p, RTSPU_PROTO)) { - res->protocol = RTSP_PROTO_UDP; + res->transports = RTSP_LOWER_TRANS_UDP | RTSP_LOWER_TRANS_UDP_MCAST; p += RTSPU_PROTO_LEN; + } else if (g_str_has_prefix (p, RTSPT_PROTO)) { + res->transports = RTSP_LOWER_TRANS_TCP; + p += RTSPT_PROTO_LEN; } else goto invalid; |