Troupble with ffmpeg MP4 to Webm

4

1

I get the error when I try to conver mp4 to webm:

Encoder (codec vp8) not found for output stream #0:0

Google search tells me that I need libvpx installed, but I've done that.

here is the rest of it:

Logans-MacBook-Pro:desktop loganmccoy$ ffmpeg -i video.mp4 -acodec libvorbis -aq 5 -ac 2 -qmax 25 -threads 2 myvideo.webm
ffmpeg version 2.8 Copyright (c) 2000-2015 the FFmpeg developers
  built with Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
  configuration: --prefix=/usr/local/Cellar/ffmpeg/2.8 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libvo-aacenc --enable-libxvid --enable-vda
  libavutil      54. 31.100 / 54. 31.100
  libavcodec     56. 60.100 / 56. 60.100
  libavformat    56. 40.101 / 56. 40.101
  libavdevice    56.  4.100 / 56.  4.100
  libavfilter     5. 40.101 /  5. 40.101
  libavresample   2.  1.  0 /  2.  1.  0
  libswscale      3.  1.101 /  3.  1.101
  libswresample   1.  2.101 /  1.  2.101
  libpostproc    53.  3.100 / 53.  3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'video.mp4':
  Metadata:
    major_brand     : M4V 
    minor_version   : 1
    compatible_brands: M4V mp42isom
    creation_time   : 2015-09-21 06:30:12
  Duration: 00:00:10.58, start: 0.000000, bitrate: 1264 kb/s
    Stream #0:0(eng): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, bt709), 1280x720, 1253 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      creation_time   : 2015-09-21 06:30:12
      handler_name    : Mainconcept MP4 Video Media Handler
      encoder         : AVC Coding
File 'myvideo.webm' already exists. Overwrite ? [y/N] y
Output #0, webm, to 'myvideo.webm':
  Metadata:
    major_brand     : M4V 
    minor_version   : 1
    compatible_brands: M4V mp42isom
    Stream #0:0(eng): Video: vp8, none, q=2-31, 128 kb/s (default)
    Metadata:
      creation_time   : 2015-09-21 06:30:12
      handler_name    : Mainconcept MP4 Video Media Handler
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> ? (?))
Encoder (codec vp8) not found for output stream #0:0

Any ideas?

Pat

Posted 2015-09-21T16:37:52.333

Reputation: 51

Answers

1

You may have installed libvpx, but your ffmpeg build is missing --enable-libvpx (and --enable-libvorbis or --enable-libopus), and therefore has not been configured to support it.

You can compile ffmpeg, but the easiest method is to simply download a static build of ffmpeg: it has libvpx support.

llogan

Posted 2015-09-21T16:37:52.333

Reputation: 31 929

I installed with homebrew: 'brew install ffmpeg --with-fdk-aac --with-ffplay --with-freetype --with-libass --with-libquvi --with-libvorbis --with-libvpx --with-opus --with-x265' This should have built it with libvpx, correct? – Pat – 2015-09-21T16:59:40.257

I did brew info ffmpeg and it shows that it's been built with libvpx: Build: pkg-config ✔, texi2html ✔, yasm ✔ Recommended: x264 ✔, lame ✔, libvo-aacenc ✔, xvid ✔ Optional: faac ✘, fontconfig ✔, freetype ✔, theora ✘, libvorbis ✔, libvpx ✔, rtmpdump ✘, opencore-amr ✘, libass ✔, openjpeg ✘, speex ✘, schroedinger ✘, fdk-aac ✔, opus ✔, frei0r ✘, libcaca ✘, libbluray ✘, libsoxr ✘, libquvi ✔, libvidstab ✘, x265 ✔, openssl ✔, libssh ✘, webp ✘, zeromq ✘ Any ideas? – Pat – 2015-09-21T17:18:19.733

@Logan I don't have a OS X machine to test with. Are you sure there aren't multiple ffmpeg binaries installed? Did brew provide any information regarding the missing libraries? – llogan – 2015-09-21T18:42:47.550

I have to be honest I'm not sure what you mean by multiple binaries. I only installed it once through brew if that's what you mean. I'm a little new to this. Also, as far as I know brew installed ffmpeg with the library I need to convert to webm, which is why I'm confused about the error – Pat – 2015-09-21T18:49:27.140