michaelmob/WebMCam

Issue with latest FFmpeg and auto_alt_ref argument

Closed this issue · 4 comments

I am on Windows 10, and am using the current latest static Windows build from Zeranoe (20170117-f7e9275). Recording was successful, but an error occurs during the FFmpeg process.

Input #0, image2, from '%d.png':
  Duration: 00:00:01.23, start: 0.000000, bitrate: N/A
    Stream #0:0: Video: png, rgba(pc), 479x393 [SAR 4724:4724 DAR 479:393], 30 fps, 30 tbr, 30 tbn, 30 tbc
[libvpx @ 0000000000778560] v1.6.0
[libvpx @ 0000000000778560] Transparency encoding with auto_alt_ref does not work
Stream mapping:
  Stream #0:0 -> #0:0 (png (native) -> vp8 (libvpx))
Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

I googled a little bit and stumbled on a StackOverflow question. It appears that the error message on auto_alt_ref is significant enough, and needs to disabled via -auto-alt-ref 0. After including it into my FFmpeg arguments, FFmpeg was able to process the WebM.

I do not know what auto_alt_ref does, and the wiki only states:

-auto-alt-ref
Enable use of alternate reference frames (2-pass only)
(0 disabled, 1 enabled <default 0>)

It looks like its enabled in the new builds? Should WebMCam include this argument by default?

Absolutely. I'll fix this today. Great work!

I'm still having this issue on Windows 10 with 2.4.0.

ffmpeg version N-83152-gf7e9275 Copyright (c) 2000-2017 the FFmpeg developers
  built with gcc 5.4.0 (GCC)
  configuration: --enable-gpl --enable-version3 --enable-cuda --enable-cuvid --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-nvenc --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-decklink --enable-zlib
  libavutil      55. 43.100 / 55. 43.100
  libavcodec     57. 74.100 / 57. 74.100
  libavformat    57. 62.100 / 57. 62.100
  libavdevice    57.  2.100 / 57.  2.100
  libavfilter     6. 69.100 /  6. 69.100
  libswscale      4.  3.101 /  4.  3.101
  libswresample   2.  4.100 /  2.  4.100
  libpostproc    54.  2.100 / 54.  2.100
Input #0, image2, from '%d.png':
  Duration: 00:00:00.42, start: 0.000000, bitrate: N/A
    Stream #0:0: Video: png, rgba(pc), 359x319 [SAR 3779:3779 DAR 359:319], 60 fps, 60 tbr, 60 tbn, 60 tbc
[libvpx @ 00000000025d44a0] v1.6.0
[libvpx @ 00000000025d44a0] Transparency encoding with auto_alt_ref does not work
Stream mapping:
  Stream #0:0 -> #0:0 (png (native) -> vp8 (libvpx))
Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

@slx7R4GDZM under Options > FFmpeg Arguments, is -auto-alt-ref 0 present? As an example, this is the default FFmpeg Arguments content, which can be found when you Reset Arguments:

-framerate {fps:avg} -i {format} {audio} -c:v {codec} -auto-alt-ref 0 -b:v 2M -r {fps:avg} {output}

If its not there, try copy/pasting the argument into the FFmpeg Arguments field, and attempt to record again.

@slx7R4GDZM under Options > FFmpeg Arguments, is -auto-alt-ref 0 present?

It wasn't. Thanks, that fixed it.