C
C
Cyril2020-07-08 09:47:43
Video
Cyril, 2020-07-08 09:47:43

What ffmpeg arguments to use to convert ANY video format to mp4?

There was a need to convert the downloaded video file of any format to mp4 . Is there a universal set of command line arguments for ffmpeg to compress, optimize and convert any input video file to mp4?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
@
@nidalee, 2020-07-08
@belyaevcyrill

My suggestion:

ffmpeg -i файл -c:v libx264 -preset slow -crf 22 -c:a copy результат.mp4

You can do the same in a bat file so that the name picks up:
@echo off
:START
if "%~1" == "" goto END
ffmpeg -i "%~1" -c:v libx264 -preset slow -crf 22 -c:a copy "%~1".mp4 -y
shift
goto START
:END
PAUSE
You just need to drag the desired video onto this bat-file. Easily corresponds to the answer Sergey Tikhonov
Here is another answer on the topic.
UP: Technically, ffmpeg doesn't do everything. For example, it will not digest r3d files. But I don't think you will run into them.

S
Sergey Tikhonov, 2020-07-08
@tumbler

ffmpeg -i <anyfile> output.mp4- nowhere more versatile

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question