树莓派+官方摄像头模块+VLC串流实时输出网络视频流
2016-03-06 19:29
609 查看
sudo apt-get update sudo apt-get install vlc sudo raspivid -o - -t 0 -w 640 -h 360 -fps 25|cvlc -vvv stream:///dev/stdin --sout '#standard{access=http,mux=ts,dst=:8090}' :demux=h264
在电脑端,无论是Windows,Linux还是OSX,或者安卓机器,只要能安装VLC,现在就可以打开VLC,然后打开媒体-》网络串流-》输入http://PI的IP地址:8090查看实时不卡的网络监控了。
第一行是更新软件数据库
第二行是安装vlc
第三行是使用PI官方的raspivid捕获视频工具把视频流输出到vlc,通过vlc转码成h264网络视频流通过http协议以ts的形式封装,然后输出到8090端口,用这个当监控只要网络稳定绝对不卡。
看到以下内容就说明开始正常输出内容了。然后在其它VLC客户端打开网络串流就行了。
[0xd604f0] packetizer_h264 demux packetizer debug: found NAL_PPS (pps_id=0 sps_id=0) [0xce6458] main input debug: selecting program id=0 [0xd522f8] main decoder debug: looking for packetizer module: 21 candidates [0xd522f8] main decoder debug: using packetizer module "packetizer_h264" [0xd522f8] main decoder debug: TIMER module_need() : 0.912 ms - Total 0.912 ms / 1 intvls) [0xce6458] main input error: Invalid PCR value in ES_OUT_SET_(GROUP_)PCR ! [0xce6458] main input debug: switching to sync mode [0xce6458] main input debug: Buffering 0% [0xd522f8] packetizer_h264 decoder debug: found NAL_SPS (sps_id=0) [0xd522f8] packetizer_h264 decoder debug: found NAL_PPS (pps_id=0 sps_id=0) [0xce6458] main input debug: Buffering 13% [0xd5ac40] main stream output debug: adding a new sout input (sout_input:0xcee4d8) [0xd5d270] main mux debug: adding a new input [0xd5d270] mux_ts mux debug: adding input codec=h264 pid=68 [0xd5d270] mux_ts mux debug: new PCR PID is 68 [0xce6458] main input debug: Buffering 26% [0xce6458] main input debug: Buffering 40% [0xce6458] main input debug: Buffering 53% [0xce6458] main input debug: Buffering 66% [0xce6458] main input debug: Buffering 80% [0xce6458] main input debug: Buffering 93% [0xce6458] main input debug: Stream buffering done (320 ms in 22 ms) [0xce6458] main input debug: Decoder buffering done in 0 ms [0xd5d270] main mux warning: late buffer for mux input (30138) [0xd5d270] mux_ts mux warning: packet with too strange dts (dts=5834500483,old=5837242731) [0xd5d270] mux_ts mux warning: packet with too strange dts (dts=5834706185,old=5834740483)
参考:http://bbs.ickey.cn/group-topic-id-14728.html
相关文章推荐
- 卷积神经网络(CNN)的简单实现(MNIST)
- 卷积神经网络(CNN)的简单实现(MNIST)
- 网络电视精灵
- [网络流24题][CODEVS1904]最小路径覆盖问题(最大流||匈牙利算法)
- Dorado7环境配置启动,Tomcat7启动正常,http://localhost:8080不能正常访问,返回404错误
- tcp协议数据传输“粘包”分析
- java网络编程
- 工信部出台《网络出版服务管理规定》
- 请求网络中GET和POST的学习理解
- HTTP的理解学习
- 基于Netty4的HttpServer和HttpClient的简单实现
- 苹果iphone4s完美越狱后破解4g网络方法
- [总结]有上下界的网络流
- Android Http请求方法汇总
- WebSocket之获取HttpSession
- TCP的四种定时器简单记录
- HttpClient和HttpURLConnection的区别
- CNN(卷积神经网络)、RNN(循环神经网络)、DNN(深度神经网络)的内部网络结构有什么区别?
- 【网络流24题】圆桌问题
- TCP/IP Note4