Streaming Mp4 video through RTP protocol using Gstreamer in Ubuntu

杀马特。学长 韩版系。学妹 提交于 2019-12-04 16:33:38

Below is the pipeline for receiver

Sender:

gst-launch-1.0 -v filesrc location = video.mp4 ! decodebin ! x264enc ! rtph264pay ! udpsink host=192.168.1.159 port=5000

will output CAPS use this caps at the receiver side:

caps="application/x-rtp, media=video, clock-rate=90000, encoding-name=H264, payload=96, ssrc=3394826012, timestamp-offset=2215812541, seqnum-offset=46353"

Receiver:

gst-launch-1.0 -v udpsrc port=5000 caps="application/x-rtp, media=video, clock-rate=90000, encoding-name=H264, payload=96, ssrc=3394826012, timestamp-offset=2215812541, seqnum-offset=46353" ! rtph264depay ! decodebin ! videoconvert ! autovideosink sync=false

hence you will be able to stream and video will be smooth and clean. In above pipeline if you are using gst-launch-0.10 then replace videoconvert with ffmpegcolorspace

Finally i will be able to see some video in launch screen.I have used the following pipeline.But the video is not clear.

SERVER:

gst-launch-0.10 -v filesrc location=/home/gokul/video.mp4 ! qtdemux name=d ! queue ! rtpmp4vpay ! udpsink port=5000

CLIENT:

gst-launch-0.10 udpsrc port=5000 caps = "application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)MP4V-ES, profile-level-id=(string)243, config=(string)000001b0f3000001b50ee040c0cf0000010000000120008440fa282fa0f0a21f, payload=(int)96, ssrc=(uint)4291479415, clock-base=(uint)4002140493, seqnum-base=(uint)57180" ! rtpmp4vdepay ! ffdec_mpeg4 ! xvimagesink sync=false

So can anyone suggest me how to enhance the video image in the client side,by modifying of adding some of the pipeline parameters.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!