如何用ffmpeg获取USB摄像头数据并存储到本地
1个回答
推荐于2016-05-08
展开全部
我用的命令是
ffmpeg -f video4linux -s 320*240 -r 10 -i /dev/video0 test.asf
运行的结果是
FFmpeg version SVN-r16967, Copyright (c) 2000-2009 Fabrice Bellard, et al.
configuration: --enable-pthreads --enable-x11grab --enable-memalign-hack --enable-gpl --enable-libmp3lame --disable-vhook
libavutil 49.14. 0 / 49.14. 0
libavcodec 52.11. 0 / 52.11. 0
libavformat 52.25. 0 / 52.25. 0
libavdevice 52. 1. 0 / 52. 1. 0
built on Feb 3 2009 15:22:03, gcc: 4.3.2
Input #0, video4linux, from '/dev/video0':
Duration: N/A, start: 1233715988.062058, bitrate: 9216 kb/s
Stream #0.0: Video: rawvideo, yuv420p, 320x240, 9216 kb/s, 10.00 tb(r)
Output #0, asf, to 'test.asf':
Stream #0.0: Video: msmpeg4, yuv420p, 320x240, q=2-31, 200 kb/s, 10.00 tb(c)
Stream mapping:
Stream #0.0 -> #0.0
Press [q] to stop encoding
VIDIOCMCAPTURE: Invalid argument
frame= 1 fps= 0 q=6.5 Lsize= 32kB time=0.10 bitrate=2594.5kbits/s
video:28kB audio:0kB global headers:0kB muxing overhead 11.194542%
ffmpeg -f video4linux -s 320*240 -r 10 -i /dev/video0 test.asf
运行的结果是
FFmpeg version SVN-r16967, Copyright (c) 2000-2009 Fabrice Bellard, et al.
configuration: --enable-pthreads --enable-x11grab --enable-memalign-hack --enable-gpl --enable-libmp3lame --disable-vhook
libavutil 49.14. 0 / 49.14. 0
libavcodec 52.11. 0 / 52.11. 0
libavformat 52.25. 0 / 52.25. 0
libavdevice 52. 1. 0 / 52. 1. 0
built on Feb 3 2009 15:22:03, gcc: 4.3.2
Input #0, video4linux, from '/dev/video0':
Duration: N/A, start: 1233715988.062058, bitrate: 9216 kb/s
Stream #0.0: Video: rawvideo, yuv420p, 320x240, 9216 kb/s, 10.00 tb(r)
Output #0, asf, to 'test.asf':
Stream #0.0: Video: msmpeg4, yuv420p, 320x240, q=2-31, 200 kb/s, 10.00 tb(c)
Stream mapping:
Stream #0.0 -> #0.0
Press [q] to stop encoding
VIDIOCMCAPTURE: Invalid argument
frame= 1 fps= 0 q=6.5 Lsize= 32kB time=0.10 bitrate=2594.5kbits/s
video:28kB audio:0kB global headers:0kB muxing overhead 11.194542%
本回答被提问者和网友采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
镭速传输
2024-10-28 广告
2024-10-28 广告
远程传输大文件选择《镭速远程大文件传输解决方案》,专为企业级大数据优化,提供高效稳定的远距离大文件传输解决方案。其核心优势包括全程智能压缩、断点续传技术,显著提升文件传输速度,最高可达100倍提速。此外,镭速还支持跨国远距离大数据传输,解决...
点击进入详情页
本回答由镭速传输提供
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询