Newest 'libx264' Questions - Stack Overflow
Les articles publiés sur le site
-
"Unknown Encoder 'libx264'" error while using FFMPEG
9 juillet 2018, par newuserI have followed the guide given here @ traq.ffmpeg. And everything goes smoothly. But when I try to run a command with FFMPEG to convert something to h.264, I get the error:
Unknown Encoder 'libx264'
I'm using Ubuntu 16.04 LTS.
-
Unknown Encoder error when using libx264 with FFMPEG
9 juillet 2018, par newuserI have followed the guide given here. And everything goes smoothly. But when I try to run a command with FFMPEG to convert to H.264. I get the error: Unknown Encoder 'libx264' I'm on Ubuntu 16.04 LTS.
-
Unknown encoder 'libx264' error in AWS EC2
6 juillet 2018, par Krzysztof PastorczykI installed ffmpeg using the following config file:
packages: yum: ImageMagick: [] ImageMagick-devel: [] commands: 01-wget: command: "wget -O /tmp/ffmpeg.tar.xz https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-64bit-static.tar.xz" 02-mkdir: command: "if [ ! -d /opt/ffmpeg ] ; then mkdir -p /opt/ffmpeg; fi" 03-tar: command: "tar xvf /tmp/ffmpeg.tar.xz -C /opt/ffmpeg --strip 1" 04-ln: command: "if [[ ! -f /usr/bin/ffmpeg ]] ; then ln -sf /opt/ffmpeg/ffmpeg /usr/bin/ffmpeg; fi" 05-ln: command: "if [[ ! -f /usr/bin/ffprobe ]] ; then ln -sf /opt/ffmpeg/ffprobe /usr/bin/ffprobe; fi" 06-pecl: command: "if [ `pecl list | grep imagick` ] ; then pecl install -f imagick; fi"
Unfortunatelly during the encode process from carrierwave-video I get the following error:Unknown encoder 'libx264' (FFMPEG::Error) from gems/streamio-ffmpeg-3.0.2/lib/ffmpeg/transcoder.rb:45:in `run' from gems/streamio-ffmpeg-3.0.2/lib/ffmpeg/movie.rb:200:in `transcode' from gems/carrierwave-video-0.6.0/lib/carrierwave/video.rb:68:in `block in encode_video' from gems/carrierwave-video-0.6.0/lib/carrierwave/video.rb:81:in `with_trancoding_callbacks' from gems/carrierwave-video-0.6.0/lib/carrierwave/video.rb:62:in `encode_video' from app/uploaders/file_uploader.rb:21:in `encode'
I guess I'll need to install 'libx264'. Do you know how can I do this on Elastic beanstalk?
Problem solved. I used different codec.
encode_video(:mp4, resolution: :same, custom: %w(-vcodec mpeg4) )
-
FFmpeg version 4.0.1 cannot find h264 encoder
3 juillet 2018, par CristianoToday I updated FFmpeg to version 4.0.1 and my existing project cannot compile anymore. In particular
avcodec_find_encoder(AV_CODEC_ID_H264)
always returns null. I tried to reinstall the libx264 but nothing changed. I also tried to callavcodec_find_encoder_by_name("libx264")
and it works, butavcodec_open2()
returns error. -
FFMPEG MKV Causing Errors in DASH JS
24 juin 2018, par MikeI'm getting the following browser errors (on all browsers) using Dash JS when transcoding and MKV file:
ERROR DOMException: Failed to read the 'buffered' property from 'SourceBuffer': This SourceBuffer has been removed from the parent media source.
and...
dash.all.min.js:26 Uncaught (in promise) DOMException: Failed to load because no supported source was found.
What's weird is I have no issues when I transcode a MP4 file. I'm using FFMPEG in conjunction with Bento4 to build MPEG DASH and HLS files for my video player.
What I did to single out FFMPEG was to transcode a video that gave me errors on my test server on my local machine (which works) and start the Bento4 process on that file. Doing that, I had no issues and everything played just fine.
I have removed FFMPEG and reinstalled it multiple times and I always get the same result. I'm sure I screwed something up on my server, but for the life of me I can't seem to figure out where to start with fixing the issue.
FFMPEG Version
ffmpeg version N-91321-ge85c608 Copyright (c) 2000-2018 the FFmpeg developers built with gcc 4.8.5 (GCC) 20150623 (Red Hat 4.8.5-28) configuration: --prefix=/root/ffmpeg_build --pkg-config-flags=--static --extra-cflags=-I/root/ffmpeg_build/include --extra-ldflags=-L/root/ffmpeg_build/lib --extra-libs=-lpthread --extra-libs=-lm --bindir=/root/bin --enable-gpl --enable-libfdk_aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libtheora --enable-libx264 --enable-nonfree libavutil 56. 18.102 / 56. 18.102 libavcodec 58. 20.102 / 58. 20.102 libavformat 58. 17.100 / 58. 17.100 libavdevice 58. 4.101 / 58. 4.101 libavfilter 7. 25.100 / 7. 25.100 libswscale 5. 2.100 / 5. 2.100 libswresample 3. 2.100 / 3. 2.100 libpostproc 55. 2.100 / 55. 2.100
FFMPEG Command
ffmpeg -i ${DIRECTORY}/${INPUT_FILE} -progress ${DIRECTORY}/transcode.log -s 1920x1080 -c:v libx264 -b:v 3000k -c:a aac -b:a 32k -minrate 3000k -maxrate 3000k -bufsize 6000k -g 96 -keyint_min 96 -sc_threshold 0 -profile:v high -flags +cgop -movflags faststart -preset ultrafast -pix_fmt yuv420p ${DIRECTORY}/ffmpeg_1920_1080_3000.mp4 &> ${DIRECTORY}/ffmpeg.log
Also, I get no errors and and if I access the output files directly, they play just fine.
I'm sure I'm not including all the information needed to troubleshoot this, so let me know if there is better information I can provide.
What would cause FFMPEG to transcode MP4 and not MKV?
EDIT One last thing, I converted the MKV to an MP4 then used the above command and it worked. It's like MP4 to MP4 is fine, but MKV to MP4 is broke.