raspberrypi 攝像頭 rtsp服務器


1.獲取樹莓派的攝像頭的視頻源並且輸出到 gstreamer中,並將數據傳輸到tcpserversink中,設定端口為5000

 raspivid -t 0 -w 800 -h 600 -fps 25 -g 5 -b 4000000 -vf -n -o - | gst-launch-1.0  fdsrc ! h264parse ! gdppay ! tcpserversink host=127.0.0.1 port=5000

 

2.在gst-rtsp-server的example中test-launch,從本機的5000端口獲取數據流作為服務器的源數據,建立rtsp的服務器。

  ./test-launch --gst-debug=3 "( tcpclientsrc host=127.0.0.1 port=5000 ! gdpdepay ! rtph264pay name=pay0 pt=96 )" 

 

3.在ubuntu14.2 中安裝gstreamer ,執行以下代碼來獲取攝像頭的圖像

 gst-launch-1.0 -v rtspsrc location=rtsp://192.168.11.22:8554/test ! gdpdepay ! rtph264depay ! avdec_h264 ! videoconvert ! autovideosink 

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM