我在Debian Wheezy的帮助下得到了ffmpeg,我试图在24小时内在一小时的时间内在办公室周围录制一些相机。
当我输入以下命令时,它记录没有问题;
ffmpeg -f mjpeg -i http://<user>:<pass>@192.168.200.220/video/mjpg.cgi -acodec copy -vcodec copy ~/data/temp.mp4
当我尝试以下包含段的命令时,它不会开始录制。
ffmpeg -f mjpeg -i http://<user>:<pass>@192.168.200.220/video/mjpg.cgi -acodec copy -vcodec copy -y -f segment -segment_time 3600 -segment_wrap 24 ~/data/temp%03d.mp4
这是完整的错误;
ffmpeg version 1.0.10 Copyright (c) 2000-2014 the FFmpeg developers
built on Jul 25 2014 07:50:40 with gcc 4.7 (Debian 4.7.2-5)
configuration: --prefix=/usr --extra-cflags='-g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security ' --extra-ldflags='-Wl,-z,relro' --cc='ccache cc' --enable-shared --enable-libmp3lame --enable-gpl --enable-nonfree --enable-libvorbis --enable-pthreads --enable-libfaac --enable-libxvid --enable-postproc --enable-x11grab --enable-libgsm --enable-libtheora --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libx264 --enable-libspeex --enable-nonfree --disable-stripping --enable-libvpx --enable-libschroedinger --disable-encoder=libschroedinger --enable-version3 --enable-libopenjpeg --enable-librtmp --enable-avfilter --enable-libfreetype --enable-libvo-aacenc --disable-decoder=amrnb --enable-libvo-amrwbenc --enable-libaacplus --libdir=/usr/lib/x86_64-linux-gnu --disable-vda --enable-libbluray --enable-libcdio --enable-gnutls --enable-frei0r --enable-openssl --enable-libass --enable-libopus --enable-fontconfig --enable-libfdk-aac --enable-libdc1394 --disable-altivec --dis libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
libpostproc 52. 0.100 / 52. 0.100
max_analyze_duration 5000000 reached at 5000000
[mjpeg @ 0x1750e60] Estimating duration from bitrate, this may be inaccurate
Input #0, mjpeg, from 'http://<user>:<password>@192.168.200.220/video/mjpg.cgi':
Duration: N/A, bitrate: N/A
Stream #0:0: Video: mjpeg, yuvj420p, 640x480 [SAR 1:1 DAR 4:3], 25 fps, 25 tbr, 1200k tbn, 25 tbc
Output #0, segment, to '/home/map7/data/temp3.mp4':
Output file #0 does not contain any stream
Received signal 2: terminating.
我已经为max_analyze_duration尝试了不同的设置而没有运气
更新
尝试使用ffmpeg 3.0
这有效
docker run jrottenberg/ffmpeg -i http://<user>:<pass>@192.168.200.220/video/mjpg.cgi -f mjpeg - > /media/data/temp%03d.mp4
我也让这些细分市场工作得更好但又遇到了另一个问题;
docker run -v / media / data:/ data jrottenberg / ffmpeg -i http://:@ 192.168.200.220 / video / mjpg.cgi -f segment -segment_time 5 -segment_wrap 24 /data/temp%03d.mpeg
我现在得到以下问题;
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=39 size=343ate=N/A speed=0.153x
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=229 size=332te=N/A speed=0.152x
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=1323 size=13091N/A speed=0.151x
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=3352 size=13091
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=5393 size=13091
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=7434 size=13091
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=9475 size=13091
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=11516 size=13091
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=457 size=536te=N/A speed=0.151x
[mpeg @ 0x2fea340] buffer underflow st=0 bufi=81 size=270ate=N/A speed=0.15x
^C[mpeg @ 0x2fea340] VBV buffer size not set, using default size of 130KB15x
If you want the mpeg file to be compliant to some specification
它确实输出了一些东西。
1
那是旧版本。将其更新为当前每晚。此外,输出#0名称错误,应该有三个数字?
—
Gyan
你可以从下载 johnvansickle.com/ffmpeg (对于2.6.32和更新的内核)。
—
llogan