我目前正在開發一個使用Nvidia Jetson的項目。我們需要將3臺攝像機通過UDP RTP傳輸到單一來源(單播),同時保存所有三臺攝像機的內容。Gstreamer通過RTP流式傳輸多臺攝像機,同時保存每個流
我有問題,我的管道,這可能是一個簡單的錯誤,我根本沒有看到。
gst-launch-1.0 -e v4l2src device=/dev/video0 ! 'video/x-raw, width=(int)640, height=(int)480' ! tee name=c c. ! queue ! omxvp8enc bitrate=1500000 ! rtpvp8pay ! udpsink bind-port=8574 host=129.21.57.204 port=8574 loop=false c. ! queue ! omxh264enc bitrate=1500000 ! mp4mux ! queue ! filesink location=test-RightFacingCamera.mp4 v4l2src device=/dev/video1 ! 'video/x-raw, width=(int)640, height=(int)480' ! tee name=b b. ! queue ! omxvp8enc bitrate=1500000 ! rtpvp8pay ! udpsink bind-port=8564 host=129.21.57.204 port=8564 loop=false b. ! queue ! omxh264enc bitrate=1500000 ! mp4mux ! queue ! filesink location=test-LeftFacingCamera.mp4 v4l2src device=/dev/video2 ! 'video/x-raw, width=(int)640, height=(int)480' ! tee name=a a. ! queue ! omxvp8enc bitrate=1500000 ! rtpvp8pay ! udpsink bind-port=8554 host=129.21.57.204 port=8554 loop=false a. ! queue ! omxh264enc bitrate=1500000 ! mp4mux ! queue ! filesink location=test-FrontFacingCamera.mp4
現在,這裏的問題是,3流的2將完全停止無故,沒有調試信息可言,他們會簡單地停止流,約2分鐘的時間後寫入文件。
此外,我已考慮將其轉換爲C/C++ w/Gstreamer,如果有人想指出我的方向,我不知道從哪裏開始。目前,我已經編寫了一個javascript代碼,可以通過序列號檢測每臺攝像機,併爲給定攝像機分配一個端口。然後運行這個命令。
感謝您的任何幫助。