使用ffserver实现转发实时流媒体(摄像头捕获)

简介: <p style="margin-top: 5px; margin-bottom: 5px; padding-top: 0px; padding-bottom: 0px; word-wrap: break-word; color: rgb(102, 102, 102); font-family: 宋体, Arial; font-size: 16px; line-height: 26px;">本

本系统为ubuntu 10.04LTS

说明1:本实验在本机成功测试通过;

说明2:本实验仅仅测试了视频流,未测试音频流。

1、配置ffserver.conf

-----------------------------ffserver.conf----------------------------start

Port 8090
BindAddress 0.0.0.0
MaxHTTPConnections 2000
MaxClients 1000
MaxBandwidth 1000
CustomLog -
NoDaemon


File /tmp/feed1.ffm
FileMaxSize 200K
ACL allow 127.0.0.1

Feed feed1.ffm
Format mpeg
VideoBitRate 64
VideoBufferSize 40
VideoFrameRate 3
VideoSize 352x240
VideoGopSize 12
NoAudio


Format status
ACL allow localhost
ACL allow 192.168.0.0 192.168.255.255
-----------------------------ffserver.conf----------------------------end

2、启动ffserver

命令: ffserver -f doc/ffserver.conf

3、检查服务器状态

在web浏览器中输入地址:http://localhost:8090/stat.html 

若能看到 ffserver Status 说明成功启动,通过内容可以看到在ffserver.conf配置的流信息等内容,对整个过程的成功进行有帮助

4、捕获输入流,采集到临时文件feed1.ffm

命令:ffmpeg -f video4linux2 -framerate 30 -i /dev/video0 http://localhost:8090/feed1.ffm

5、请求ffserver播放视频流

命令:ffplay http://cher-ubuntu:8090/test1.mpg

相关文章
|
Linux
linux下ffmpeg安装
<p style="border: 0px; font-family: Muli, sans-serif; font-size: 15px; margin-top: 0px; margin-bottom: 1.5em; outline: 0px; padding-top: 0px; padding-bottom: 0px; vertical-align: baseline; word-wrap
10334 57
|
C++ Python
[ROS2] --- 手动编写一个节点
[ROS2] --- 手动编写一个节点
690 1
|
Linux Windows Ubuntu
grub2与grub区别
<ul style="margin: 0px; padding: 0px; border: 0px; list-style: none; color: rgb(50, 62, 50); font-family: simsun; font-size: 14px; line-height: 21px;"> <li style="margin: 0px 0px 0px 30px; padding:
6397 0
|
存储 Linux Windows
通过grub-install命令把grub安装到u盘
<p style="margin-top: 0px; margin-bottom: 0px; padding-top: 0px; padding-bottom: 0px; color: rgb(89, 145, 0); font-family: 微软雅黑, 黑体; font-size: 18px; line-height: 20px;">通过grub-install命令把grub安装到u盘</
3374 0
|
机器学习/深度学习 算法 数据挖掘
【论文泛读】 Faster R-CNN:利用RPN实现实时目标检测
【论文泛读】 Faster R-CNN:利用RPN实现实时目标检测
【论文泛读】 Faster R-CNN:利用RPN实现实时目标检测
|
关系型数据库 MySQL Linux
linux命令--ldconfig和ldd用法
<p style="color: rgb(51, 51, 51); font-family: Arial; font-size: 14px; line-height: 26px;"><span style="font-family: 'andale mono', times;"><span style="font-size:12px;">一、ldconfig<br></span></span>
2763 0
|
Linux
linux内核initrd文件自定义方法
<span style="font-family: 'microsoft yahei';"> </span><h1 style="margin: 0px; padding: 0px; display: inline-block; vertical-align: middle; font-size: 18px; font-family: 'microsoft yahei';"><span cla
4791 0
|
Linux Shell C语言
EDKII Build Process:EDKII项目源码的配置、编译流程[三]
<p style="margin-top: 0px; margin-bottom: 0px; padding-top: 0px; padding-bottom: 0px; font-family: Tahoma; line-height: 24px; font-size: 12.381px;"><span style="margin: 0px; padding: 0px; list-style
5283 0
|
Perl 流计算 内存技术
AXI总线简介
<p style="margin-top: 14px; margin-bottom: 14px; padding-top: 0px; padding-bottom: 0px; color: rgb(46, 46, 46); font-family: 微软雅黑, 'Microsoft Yahei'; font-size: 14px; line-height: 28px; border: 0px;
5392 0
CAN控制器-配置过滤器
<p style="margin-top: 0px; margin-bottom: 0px; padding-top: 0px; padding-bottom: 0px; font-family: Arial; font-size: 14px; line-height: 26px;"><span style="font-size: 18px;">首先简单介绍一下CAN总线,关于CAN总线是谁发
2557 0

热门文章

最新文章