Difference between revisions of "GstRtspSink - Transport Stream RTSP Streaming"

From RidgeRun Developer Connection
Jump to: navigation, search
Line 12: Line 12:
 
MAPPING=/stream
 
MAPPING=/stream
  
gst-launch v4l2src ! avenc_mpeg4 ! mpegvideoparse ! mpegtsmux ! capsfilter caps="video/mpegts, mapping=${MAPPING}" ! rtspsink name=sink service=$PORT
+
gst-launch-1.0 v4l2src ! avenc_mpeg4 ! mpegvideoparse ! mpegtsmux ! capsfilter caps="video/mpegts, mapping=${MAPPING}" ! rtspsink name=sink service=$PORT
 
</syntaxhighlight>
 
</syntaxhighlight>
  
Line 22: Line 22:
 
IP_ADDRESS=192.0.0.1
 
IP_ADDRESS=192.0.0.1
 
PORT=12345
 
PORT=12345
MAPPING1=/stream
+
MAPPING1=stream
  
 
vlc rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}
 
vlc rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}
Line 32: Line 32:
 
IP_ADDRESS=192.0.0.1
 
IP_ADDRESS=192.0.0.1
 
PORT=12345
 
PORT=12345
MAPPING=/stream
+
MAPPING=stream
  
 
gst-launch-1.0 rtspsrc location=rtsp://${IP_ADDRESS}:${PORT}/${MAPPING} ! rtpmp2tdepay ! mpegvideoparse ! avdec_mpeg4 ! queue ! autovideosink \
 
gst-launch-1.0 rtspsrc location=rtsp://${IP_ADDRESS}:${PORT}/${MAPPING} ! rtpmp2tdepay ! mpegvideoparse ! avdec_mpeg4 ! queue ! autovideosink \
Line 42: Line 42:
 
IP_ADDRESS=192.0.0.1
 
IP_ADDRESS=192.0.0.1
 
PORT=12345
 
PORT=12345
MAPPING=/stream
+
MAPPING=stream
  
 
mplayer rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}
 
mplayer rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}
Line 52: Line 52:
 
IP_ADDRESS=192.0.0.1
 
IP_ADDRESS=192.0.0.1
 
PORT=12345
 
PORT=12345
MAPPING=/stream
+
MAPPING=stream
  
 
totem rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}
 
totem rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}
 
</syntaxhighlight>
 
</syntaxhighlight>
 
}}
 
}}

Revision as of 22:00, 27 June 2017


TODO

Home

TODO

This wiki provides an example to send MPEG-TS through RTSP using GstRtspSink.

GstRtspSink Pipeline

The following pipeline combines takes an MPEG4 stream, encapsulates it in a Transport Stream container and sends it via RTSP.

PORT=12345
MAPPING=/stream

gst-launch-1.0 v4l2src ! avenc_mpeg4 ! mpegvideoparse ! mpegtsmux ! capsfilter caps="video/mpegts, mapping=${MAPPING}" ! rtspsink name=sink service=$PORT


RTSP Clients

VLC

IP_ADDRESS=192.0.0.1
PORT=12345
MAPPING1=stream

vlc rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}

GStreamer

IP_ADDRESS=192.0.0.1
PORT=12345
MAPPING=stream

gst-launch-1.0 rtspsrc location=rtsp://${IP_ADDRESS}:${PORT}/${MAPPING} ! rtpmp2tdepay ! mpegvideoparse ! avdec_mpeg4 ! queue ! autovideosink \

MPlayer

IP_ADDRESS=192.0.0.1
PORT=12345
MAPPING=stream

mplayer rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}

Totem

IP_ADDRESS=192.0.0.1
PORT=12345
MAPPING=stream

totem rtsp://${IP_ADDRESS}:${PORT}/${MAPPING}


TODO

Home

TODO