Video streaming Gstreamer管道的多个实例导致视频损坏?
我正在尝试使用gstreamer流4个视频。我可以毫无问题地流2个视频,但当我启动第3个gstreamer管道时,所有3个视频都会损坏。谁能告诉我为什么 这是我为观众准备的脚本/管道Video streaming Gstreamer管道的多个实例导致视频损坏?,video-streaming,gstreamer,rtp,Video Streaming,Gstreamer,Rtp,我正在尝试使用gstreamer流4个视频。我可以毫无问题地流2个视频,但当我启动第3个gstreamer管道时,所有3个视频都会损坏。谁能告诉我为什么 这是我为观众准备的脚本/管道 port="$((10000+$1*2))" cmd="gst-launch-1.0 udpsrc port=${port} ! application/x-rtp, media=video, encoding-name=H264,playload=96 ! queue ! rtph2
port="$((10000+$1*2))"
cmd="gst-launch-1.0 udpsrc port=${port} ! application/x-rtp, media=video, encoding-name=H264,playload=96 ! queue ! rtph264depay ! h264parse ! video/x-h264,alignment=au ! nvv4l2decoder disable-dpb=true enable-max-performance=1 ! queue max-size-bytes=0 ! videorate max-rate=30 ! queue ! nvvidconv ! nveglglessink window-width=720 window-height=480 sync=false"****
这是我的拖缆管道。我更新每个实例的udpsrc
端口5004/5005/5006/5007
我为每个实例更新udpsink端口10000/10002/10004/10006
udpsrc port=5004 buffer-size=60000000 ! application/x-rtp, media=video, clock-rate=90000, encoding-name=H265,playload=96 ! queue ! rtph265depay ! h265parse ! video/x-h265,alignment=au ! nvv4l2decoder disable-dpb=true enable-max-performance=1 ! queue max-size-bytes=0 ! videorate max-rate=30 ! tee name=dec dec. ! queue ! nvvidconv left=240 right=1680 top=60 bottom=1020 ! video/x-raw(memory:NVMM), format=NV12, width=360, height=240, framerate=30/1 ! nvvidconv ! video/x-raw, framerate=30/1, width=360, height=240 ! shmsink socket-path=/tmp/video0 wait-for-connection=false shm-size=60000000 dec. ! queue ! nvvidconv ! video/x-raw,width=1920,height=1080,framerate=30/1 ! qtoverlay qml=qml/main.qml ! nvvidconv ! video/x-raw(memory:NVMM), format=I420,width=1920,height=1080 ! omxh264enc ! video/x-h264,stream-format=byte-stream ! h264parse ! rtph264pay pt=96 ! tee name=ovl1 ovl1. ! udpsink host=127.0.0.1 port=10000 sync=false async=false***
我注意到,如果我不使用udpsink而只使用shmsink,视频损坏问题就会消失。所以我认为解码元素有问题?
以下是使用shmsink
udpsrc port=5007 buffer-size=60000000 ! application/x-rtp, media=video, clock-rate=90000, encoding-name=H265,playload=96 ! queue ! rtph265depay ! h265parse ! video/x-h265,alignment=au ! nvv4l2decoder disable-dpb=true enable-max-performance=1 ! queue max-size-bytes=0 ! videorate max-rate=30 ! tee name=dec dec. ! queue ! nvvidconv left=150 right=1770 top=0 bottom=1080 ! video/x-raw(memory:NVMM), format=NV12, width=360, height=240, framerate=30/1 ! tee name=dectimg dectimg. ! nvvidconv ! video/x-raw, framerate=30/1, width=360, height=240 ! shmsink socket-path=/tmp/video3 wait-for-connection=false shm-size=60000000 dec. ! queue ! nvvidconv ! video/x-raw,width=1920, height=1080, framerate=30/1 ! qtoverlay qml=qml/main.qml ! tee name=ovl ovl. ! queue ! shmsink socket-path=/tmp/camera3 wait-for-connection=false shm-size=60000000**
编辑你的问题
请稍微澄清一下您的问题,以便我们可以帮助解决问题
应用程序/x-rtp,媒体=视频,时钟频率=90000,编码名称=H265,播放负载=96
队列rtph265depay!h265parse!视频/x-h265,校准=au
nvv4l2decoder disable dpb=true启用最大性能=1
队列最大大小字节=0!视频速率最大速率=30!三通名称=十二月
十二月!队列nvvidconv left=240 right=1680 top=60 bottom=1020
视频/x-raw(内存:NVMM),格式=NV12,宽度=360,高度=240,帧速率=30/1!
nvvidconv!视频/x-raw,帧速率=30/1,宽度=360,高度=240
shmsink套接字路径=/tmp/video0等待连接=false shm size=60000000
十二月!队列nvvidconv!视频/x-raw,宽度=1920,高度=1080,帧速率=30/1
qtl=qml/main.qml!nvvidconv
视频/x-raw(内存:NVMM),格式=I420,宽度=1920,高度=1080
天哪!视频/x-h264,流格式=字节流!h264parse
RTPH264支付点=96!T形三通名称=ovl1
ovl1!udpsink主机=127.0.0.1端口=10000同步=false异步=false***
- 移除复杂的元件,例如使用T形三通制作的主管路上的任何支管
- 使用伪代码帮助描述每个管道:
- 错误输出是什么
- 损坏是否发生在拖缆端或查看器端
- 你说腐败是什么意思
- 程序崩溃了,还是继续播放