FFmpeg - Encode AVC: Difference between revisions
From PiRho Knowledgebase
Jump to navigationJump to search
mNo edit summary |
No edit summary |
||
| (One intermediate revision by one other user not shown) | |||
| Line 1: | Line 1: | ||
= FFmpeg – Encode AVC (H.264) Using CRF = | |||
[[Category:FFmpeg]] | [[Category:FFmpeg]] | ||
[[Category:AVC]] | [[Category:AVC]] | ||
== Summary == | |||
The | This article explains how to encode H.264/AVC video using CRF (Constant Rate Factor) with FFmpeg. CRF is the recommended rate‑control mode for most workflows because it prioritises consistent visual quality over exact file size. | ||
== What CRF Is == | |||
CRF is a quality‑targeted encoding mode. Instead of telling the encoder how big the output must be, you tell it what quality level you want, and the encoder decides the bitrate dynamically across the entire video. | |||
== CRF Scale Explained == | |||
The CRF scale ranges from 0 to 51. | |||
== Presets == | |||
Presets determine the speed/compression ratio balance. | |||
== Example Command == | |||
<pre> | <pre> | ||
ffmpeg -i | ffmpeg -i input.file -c:v libx264 -crf 23 -preset veryslow output.file | ||
</pre> | </pre> | ||
== References == | |||
* https://trac.ffmpeg.org/wiki/Encode/H.264 | |||
Latest revision as of 13:48, 14 March 2026
FFmpeg – Encode AVC (H.264) Using CRF
Summary
This article explains how to encode H.264/AVC video using CRF (Constant Rate Factor) with FFmpeg. CRF is the recommended rate‑control mode for most workflows because it prioritises consistent visual quality over exact file size.
What CRF Is
CRF is a quality‑targeted encoding mode. Instead of telling the encoder how big the output must be, you tell it what quality level you want, and the encoder decides the bitrate dynamically across the entire video.
CRF Scale Explained
The CRF scale ranges from 0 to 51.
Presets
Presets determine the speed/compression ratio balance.
Example Command
ffmpeg -i input.file -c:v libx264 -crf 23 -preset veryslow output.file