Re: [请益] ffmpeg

楼主: gn00618777 (非常念旧)   2014-06-20 10:03:20
※ 引述《Dickon (Deacon)》之铭言:
: 版大你好,因为我没有用ffmpeg直接操作过装置,我上网查一下资料如下
: 先查查看装置有支援哪种输出格式,指令如下
: ffmpeg -f video4linux2 -list_formats all -i /dev/video0
*** THIS PROGRAM IS DEPRECATED ***
This program is only provided for compatibility and will be removed in a
future release. Please use avconv instead.
[video4linux2 @ 0x2dba0] R : yuyv422 : YUV 4:2:2 (YUYV) : 640x480
320x240 160x120 352x288 176x144 1280x1024 1600x1200
/dev/video0: Immediate exit requested
没看到有什么支援的格式...
: 如果有支援已压缩过的格式例如 mjpeg,可以试试看
: ffmpeg -f video4linux2 -input_format mjpeg -i /dev/video0 -c:v <IP>
: 如果只有raw的话,可以试试看
: ffmpeg -f video4linux2 -i /dev/video0 <IP>
ffmpeg version 0.8.12-4:0.8.12-0ubuntu0.12.04.1, Copyright (c) 2000-2014 the Libav developers
built on Jun 10 2014 15:48:32 with gcc 4.6.3
*** THIS PROGRAM IS DEPRECATED ***
This program is only provided for compatibility and will be removed in a
future release. Please use avconv instead.
[video4linux2 @ 0x2daa0] Estimating duration from bitrate, this may be
inaccurate
Input #0, video4linux2, from '/dev/video0':
Duration: N/A, start: 55158.784487, bitrate: 48660 kb/s
Stream #0.0: Video: rawvideo, yuyv422, 352x288, 48660 kb/s, 30 tbr,
1000k tbn, 30 tbc
Sat Jan 1 15:34:32 2000 127.0.0.1 - - [GET] "/cam1.ffm HTTP/1.1" 200 4149
[buffer @ 0x2ee00] w:352 h:288 pixfmt:yuyv422
[scale @ 0x2e8c0] w:352 h:288 fmt:yuyv422 -> w:320 h:240 fmt:yuv420p flags:0x4
Sat Jan 1 15:34:32 2000 127.0.0.1 - - [POST] "/cam1.ffm HTTP/1.1" 200 0
Segmentation fault
: 会segmentation fault应该是bitrate设置错误
: 另外建议可以先用ffmpeg编译完成后附的ffserver.conf,先确定能跑起来,
: 再进行
另外有板友建议我看 muxer 是否有安装,我用 ffmpeg -formats查询
DE asf ASF format
E asf_stream ASF format
D video4linux2 Video4Linux2 device grab
====================================================================
muxer似乎是将多个串流、例如字幕、音源、影像和成某整支援的格式例如avi
encoder 似乎就是一种压缩编码技术例如 h.264,不知我认知对不对^^"
====================================================================
ffmpeg -codec
Codecs:
D..... = Decoding supported
.E.... = Encoding supported
..V... = Video codec
..A... = Audio codec
..S... = Subtitle codec
...S.. = Supports draw_horiz_band
....D. = Supports direct rendering method 1
.....T = Supports weird frame truncation
作者: qrtt1 (有些事,有时候。。。)   2014-06-20 10:10:00
ffmpeg -codecs
作者: Bencrie   2014-06-20 10:44:00
大大你装的是 libav 不是 ffmpeglibav 是从 ffmpeg fork 出来的
楼主: gn00618777 (非常念旧)   2014-06-20 10:48:00
..这我有在ffmpeg官网获得这消息,可是我仍然搞不懂这两种差别,这会导致我现在的问题吗..我在装置下 ffmpeg -f video4linux2 -i /dev/video0 cam1.asf 他可以录制且可以在装置上播放

Links booklink

Contact Us: admin [ a t ] ucptt.com