Install ffmpeg for Windows11 and PATH setting¶
Ref. JP
Download Windows EXE Files¶
-
- Get packages & executable files -> click
Windows logo
- Windows EXE Files ->
Windows builds from gyan.dev
- Get packages & executable files -> click
-
latest git master branch build ->
ffmpeg-git-full.7z
- Download and unzip
rename ffmpeg-2024-01-24-git-00b288da73-full_build
to FFmpeg
and move to under C:\Users\yuichi
PS C:\Users\yuichi> ls
ディレクトリ: C:\Users\yuichi
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 2024/01/28 23:25 FFmpeg
PS C:\Users\yuichi> cd .\FFmpeg\bin
PS C:\Users\yuichi\FFmpeg\bin> pwd
Path
----
C:\Users\yuichi\FFmpeg\bin
PATH Setting¶
Check¶
PS C:\Users\yuichi> ffmpeg -version
ffmpeg version 2024-01-24-git-00b288da73-full_build-www.gyan.dev Copyright (c) 2000-2024 the FFmpeg developers
For Final project video¶
Save Output video in another folder¶
cd path/to/presentation.mp4
mkdir -p video && ffmpeg -i presentation.mp4 -vcodec libx264 -crf 25 -preset medium -vf scale=-2:1080 -acodec libmp3lame -q:a 4 -ar 48000 -ac 2 video/presentation.mp4
If the file size is larger than 10MB, try larger number in -crf
¶
cd path/to/presentation.mp4
mkdir -p video && ffmpeg -i presentation.mp4 -vcodec libx264 -crf 30 -preset medium -vf scale=-2:1080 -acodec libmp3lame -q:a 4 -ar 48000 -ac 2 video/presentation.mp4
Note
CRF (Constant Rate Factor) is a parameter used in FFmpeg for H.264 (and H.265) video encoding to control the quality of the output video. It allows you to balance the trade-off between video quality and file size.
CRF values range from 0 to 51.
- High Quality: -crf 18
- Produces very high-quality video with a larger file size.
- Balanced Quality: -crf 23
- Provides a good balance between quality and file size, commonly used for general purposes.
- Lower Quality: -crf 28
- Results in a smaller file size with lower video quality.
Last update:
July 13, 2024