2

我正在尝试从本地目录中获取视频文件,从服务器启用流并从客户端捕获这些帧。我使用了以下管道:

服务器端:

gst-launch -v  filesrc location=/home/gokul/Videos/Econ_TestVideo/radioactive.mp4 ! qtdemux ! rtpmp4vpay ! udpsink host=192.168.7.61 port=5000 sync=true


Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
/GstPipeline:pipeline0/GstRtpMP4VPay:rtpmp4vpay0.GstPad:src: caps = application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)MP4V-ES, profile-level-id=(string)1, config=(string)000001b001000001b58913000001000000012000c48d8800f528045a1443000001b24c61766335332e33352e30, payload=(int)96, ssrc=(uint)3003638799, clock-base=(uint)1542273545, seqnum-base=(uint)49176
/GstPipeline:pipeline0/GstRtpMP4VPay:rtpmp4vpay0.GstPad:sink: caps = video/mpeg, mpegversion=(int)4, systemstream=(boolean)false, profile=(string)simple, level=(string)1, codec_data=(buffer)000001b001000001b58913000001000000012000c48d8800f528045a1443000001b24c61766335332e33352e30, width=(int)1280, height=(int)720, framerate=(fraction)91/3, pixel-aspect-ratio=(fraction)1/1
/GstPipeline:pipeline0/GstRtpMP4VPay:rtpmp4vpay0: timestamp = 1542273545
/GstPipeline:pipeline0/GstRtpMP4VPay:rtpmp4vpay0: seqnum = 49176
/GstPipeline:pipeline0/GstUDPSink:udpsink0.GstPad:sink: caps = application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)MP4V-ES, profile-level-id=(string)1, config=(string)000001b001000001b58913000001000000012000c48d8800f528045a1443000001b24c61766335332e33352e30, payload=(int)96, ssrc=(uint)3003638799, clock-base=(uint)1542273545, seqnum-base=(uint)49176
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock

客户端:

gst-launch -v udpsrc port=5000 caps="application/x-rtp" ! rtpmp4vdepay ! mpeg4videoparse ! queue ! ffdec_mpeg4 ! ffmpegcolorspace !  xvimagesink


Setting pipeline to PAUSED ...
/GstPipeline:pipeline0/GstUDPSrc:udpsrc0.GstPad:src: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)1, encoding-name=(string)MP4V-ES
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock

设置这些后,我没有看到任何显示(甚至没有启动应用程序屏幕)

要添加到上述信息,我在 Ubuntu-12.04 的命令行中运行这些命令

4

2 回答 2

4

下面是接收器的管道

发件人:

gst-launch-1.0 -v filesrc 位置 = video.mp4 !解码器!x264enc !rtph264pay!udpsink 主机=192.168.1.159 端口=5000

将输出 CAPS 在接收器端使用此大写:

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

接收者:

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!解码器!视频转换!自动视频接收器同步 = 假

因此,您将能够流式传输并且视频将流畅和干净。在上述管道中,如果您使用的是 gst-launch-0.10,则将 videoconvert 替换为 ffmpegcolorspace

于 2016-03-08T06:10:23.117 回答
0

最后我将能够在启动屏幕中看到一些视频。我使用了以下管道。但视频不清楚。

服务器:

gst-launch-0.10 -v filesrc location=/home/gokul/video.mp4 !qtdemux 名称=d !队列 !rtpmp4vpay!udpsink 端口=5000

客户:

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 =(字符串)243,配置=(字符串)000001b0f3000001b50ee040c0cf0000010000000120008440fa282fa0f0a21f,有效负载=(int)96,ssrc=(uint)4291479415,时钟基数=(uint)40021(uint)40021(uint)40021(40493,seqnum-base)rtpmp4vdepay !ffdec_mpeg4 !xvimagesink 同步=假

那么任何人都可以建议我如何通过修改添加一些管道参数来增强客户端的视频图像。

于 2014-12-18T13:44:49.193 回答