[RBP] RaspberryPi系列之四:RBP as a streaming server(一)
来源:互联网 发布:linux修改机器时间 编辑:程序博客网 时间:2024/06/05 10:31
1. Raspberry Pi camera software
一旦安装好Pi摄像头,RBP的开发者们提供了两个简单但强大的命令行工具,用来直接对摄像头获取的图像或视频流进行保存或分流
raspivid is a command line application that allows you to capture video with the camera module
raspistill allows you to capture images
Example Commands
(http://www.raspberrypi.org/archives/3890)
Capture an image in jpeg format:
raspistill -o image.jpg
Capture a 5s video in h264 format:
raspivid -o video.h264
Capture a 10s video:
raspivid -o video.h264 -t 10000
Capture a 10s video in demo mode:
raspivid -o video.h264 -t 10000 -d
To see a list of possible options for running raspivid orraspistill, you can run:
raspivid | less
raspistill | less
How to install the Raspberry Pi camera module
http://www.techradar.com/news/computing-components/peripherals/how-to-install-the-raspberry-pi-camera-module-1172034
Display a five-second demo: raspivid -d
Display a 640x480 preview: raspivid -p 0,0,640,480
Capture 20s of h264 video: raspivid -t 20000 -o video.h264
Take a 640x480 shot: raspistill -o image.jpg -w 640 -h 480
Take a reduced quality JPEG: raspistill -o image.jpg -q 5
2. Streaming video in RBP native way (Without OpenCV)
RBP的作者们还演示了一种通过网络stream视频流的方式。
在Pi上需要用到raspivid和netcat
raspivid -t 999999 -o – | nc [insert the IP address of the client] 5001
在客户端(包括Linux, Windows和Mac)运行netcat和mplayer即可。比如Linux下只要:
nc -l -p 5001 | mplayer -fps 31 -cache 1024 -
但我如果运行上面命令则直接退出,
libavformat version 53.21.1 (external)
Mismatching header version 53.19.0
Exiting... (End of file)
运行
nc.traditional -l -p 5001 | mplayer -fps 31 -cache 1024 -
就一切正常。
- [RBP] RaspberryPi系列之四:RBP as a streaming server(一)
- [RBP]RaspberryPi系列之五:RBP as a streaming server (二)
- RBP as a streaming server(一)
- [RBP]RaspberryPi系列之二:RBP+OpenCV-FaceRecognition
- [RBP] RaspberryPi系列之附二:重设密码
- [RBP] RaspberryPi系列之附一:Linux下视频编程(v4l2编程)
- [RBP]RaspberryPi系列之三:NEW seven-part OpenCV 2.4.6.1 and Pi Camera Board - Updated!
- [RBP] RaspberryPi系列之一:Linux下网络配置
- RaspberryPi 3B 之初体验笔记(续一)
- *nux编程的108种奇淫巧计-5(rbp寄存器)
- 编译Qt/E时遇到incorrect register `%rbp' used with `l' suffix问题的解决办法
- Hadoop 实战之Streaming(四)
- Hadoop 实战之Streaming(四)
- 大数据系列之(一) Streaming模式基础知识
- Hadoop 实战之Streaming(一)
- Hadoop 实战之Streaming(一)
- tensorflow笔记(四)之MNIST手写识别系列一
- tensorflow笔记(四)之MNIST手写识别系列一
- select选择框控件-jquery.editable-select
- 最简单的WINSOCK通讯模型
- 侥幸过关,还有1年
- Jackson Streaming API To Read And Write JSON
- The install progress of bochs 2.4.6
- [RBP] RaspberryPi系列之四:RBP as a streaming server(一)
- KEIL编译错误信息表
- Hadoop 2 + HBase 0.94 相关资料
- CentOS设置服务开机启动的方法
- PHP防CC攻击防止快速刷新代码
- PHP判断是否为AJAX请求
- Linux下环境[LAMP]搭建教程
- PHP中ob_start()函数相关应用
- Mac环境Eclipse下艰难安装PyDev