I'm trying to merge two videos (like here) side by side.
The full log with command:

    ffmpeg -i input1.mp4 -i input2.mp4 -filter_complex '[0:v]pad=iw*2:ih[int];[int][1:v]overlay=W/2:0[vid]' -map [vid] -c:v libx264 -crf 23 -preset veryfast output.mp4
ffmpeg version N-90232-g0645698ecc Copyright (c) 2000-2018 the FFmpeg developers
  built with gcc 7 (Ubuntu 7.2.0-8ubuntu3.2)
  configuration: --disable-x86asm
  libavutil      56.  8.100 / 56.  8.100
  libavcodec     58. 13.102 / 58. 13.102
  libavformat    58. 10.100 / 58. 10.100
  libavdevice    58.  2.100 / 58.  2.100
  libavfilter     7. 12.100 /  7. 12.100
  libswscale      5.  0.102 /  5.  0.102
  libswresample   3.  0.101 /  3.  0.101
Unrecognized option 'crf'.
Error splitting the argument list: Option not found

But getting message mentioned in the title.
I have ffmpeg version N-90232-g0645698ecc from Ubuntu 17.10 repos.

  • Share full log.
    – Gyan
    Mar 12 '18 at 18:12
  • @Mulvya done, take a look, please.
    – R S
    Mar 12 '18 at 18:49
  • You need a ffmpeg binary with libx264 included. Get it from johnvansickle.com/ffmpeg
    – Gyan
    Mar 12 '18 at 19:09
  • @Mulvya thanks, also I would appreciate if someone knows how to make it work with usual build.
    – R S
    Mar 12 '18 at 22:29
  • 1
    @RS Your version N-90232-g0645698ecc is not from the repo. It looks like a compiled version. See trac.ffmpeg.org/wiki/CompilationGuide/Ubuntu for compile guide, or just use the actual ffmpeg package from the repo.
    – llogan
    Mar 12 '18 at 23:01

Your ffmpeg is not from the Ubuntu 17.10 repo and looks like it was compiled on your machine. It lacks --enable-gpl --enable-libx264 which is required to use -c:v libx264. Unrelated, but it has --disable-x86asm which is never recommended as it will result in slowness.

You have several options to fix this:

  • 1
    Can you tell me how to use the above command in Android using bravobit android dependencies ? Aug 17 '18 at 8:45
  • @VivekMishra I don't know anything about bravobit android dependencies. I recommend asking a new question.
    – llogan
    Aug 17 '18 at 16:33

In my case was anaconda3 which my system was calling ( and installling, removing, etc didn't fix my problem), you could find out if it is your case with:

whereis ffmpeg

After that I saw all the possible path, the system was calling conda version instead of system version. To be sure you have a compatible version with --crf install it with:

sudo apt-get install ffmpeg

then for calling with it, you should use the path from the system or modify your PATH variables (this is modify ~/.profile or ~/.bash or more options and how it works here). I didn't do that because everything works with ffmpeg conda version except the --crf argument.

How to use the compatible version with --crf

/usr/bin/ffmpeg -i input.mp4 -vcodec libx265 -crf 28 output.mp4

Where /usr/bin/ffmpeg is a one of the results of whereis ffmpeg

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.