Log in

View Full Version : ffmpeg: Unknown decoder 'libx264'


Sirber
1st September 2010, 15:14
ffmpeg.exe -pass 1 -vcodec libx264 -passlogfile out.mp4 -i test.avi -b 368k -maxrate 600k -y out.mp4
FFmpeg version SVN-r25015, Copyright (c) 2000-2010 the FFmpeg developers
built on Sep 1 2010 04:13:18 with gcc 4.4.2
configuration: --enable-gpl --enable-version3 --enable-libgsm --enable-pthread
s --enable-libvorbis --enable-libtheora --enable-libspeex --enable-libmp3lame --
enable-libopenjpeg --enable-libschroedinger --enable-libopencore_amrwb --enable-
libopencore_amrnb --enable-libvpx --arch=x86 --enable-runtime-cpudetect --enable
-libxvid --enable-libx264 --extra-libs='-lx264 -lpthread' --enable-librtmp --ext
ra-libs='-lrtmp -lpolarssl -lws2_32 -lwinmm' --target-os=mingw32 --enable-avisyn
th --cross-prefix=i686-mingw32- --cc='ccache i686-mingw32-gcc' --enable-memalign
-hack
libavutil 50.24. 0 / 50.24. 0
libavcore 0. 6. 0 / 0. 6. 0
libavcodec 52.87. 0 / 52.87. 0
libavformat 52.78. 3 / 52.78. 3
libavdevice 52. 2. 1 / 52. 2. 1
libavfilter 1.38. 1 / 1.38. 1
libswscale 0.11. 0 / 0.11. 0
Unknown decoder 'libx264'

but the lib "libx264" seems to be in.
I got my build here: http://ffmpeg.arrozcru.org/autobuilds/

source is divx5/mp3/avi and encodes well in "webm" using the same ffmpeg build.

thanks!

sneaker_ger
1st September 2010, 15:38
No problem here using r25015-win32 from that site on a xvid/mp3 source:
ffmpeg -i input.avi -vcodec libx264 -acodec libvorbis -fpre presets\libx264-ultrafast.ffpreset output.mkv

sneaker_ger
1st September 2010, 15:50
Ok, try the following:
ffmpeg.exe -i input.avi -vcodec libx264 -pass 1 -b 368k -passlogfile out.log -fpre presets/libx264-medium_firstpass.ffpreset -y out.mp4

ffmpeg.exe -i input.avi -vcodec libx264 -pass 2 -b 368k -passlogfile out.log -fpre presets/libx264-medium.ffpreset -y out.mp4

Also note that you need to set a bufsize in order to use maxrate.

Sirber
1st September 2010, 15:55
Ok, try the following:
ffmpeg.exe -i input.avi -vcodec libx264 -pass 1 -b 368k -passlogfile out.log -fpre presets/libx264-medium_firstpass.ffpreset -y out.mp4

ffmpeg.exe -i input.avi -vcodec libx264 -pass 2 -b 368k -passlogfile out.log -fpre presets/libx264-medium.ffpreset -y out.mp4

Also note that you need to set a bufsize in order to use maxrate.

that works! thank you! :D

looks like I need "-i" as first argument and to use a preset file. I cannot blankly run it.

pasteeater
4th September 2010, 01:50
You don't need to perform a two-pass encode unless you are targeting a specific output file size. Use single-pass Constant Rate Factor (CRF) when you care more about quality than output file size. See the FFmpeg x264 encoding guide (http://rob.opendot.cl/index.php/useful-stuff/ffmpeg-x264-encoding-guide/) for some sane examples.