Librav1e Speed Presets and Video Quality Explained
This article provides an overview of the speed presets available in
the librav1e AV1 video encoder and examines how they
influence encoding speed, compression efficiency, and visual quality. By
understanding the trade-offs between the presets, which range from 0 to
10, you can select the optimal configuration for your specific video
processing pipeline.
The Speed-to-Quality Trade-off in librav1e
The librav1e encoder, the FFmpeg wrapper for the
Rust-based rav1e AV1 encoder, utilizes a numerical preset
system from 0 to 10.
- Lower numbers (e.g., 0, 1, 2) prioritize compression efficiency and visual quality at the expense of computational time.
- Higher numbers (e.g., 8, 9, 10) prioritize encoding speed, sacrificing compression efficiency and resulting in larger file sizes or lower quality at a fixed bitrate.
The relationship is non-linear. As you move toward slower presets, the encoder enables advanced coding tools and deeper partitioning searches, which exponentially increase CPU usage for diminishing returns in file size savings.
Detailed Breakdown of Presets
Presets 0 to 2: Maximum Quality (Archival)
- Speed: Extremely slow.
- Quality: Highest possible quality per megabyte.
- Use Case: Deep archiving, reference encodes, or encoding very short clips where storage efficiency is the absolute priority.
- Impact: These settings enable exhaustive search algorithms for motion estimation and block partitioning. They are generally too slow for practical, everyday use on standard consumer hardware.
Presets 3 to 5: High Quality (Standard Encoding)
- Speed: Slow to moderate.
- Quality: Excellent compression efficiency with significant file size reduction.
- Use Case: High-quality distribution of movie files, high-fidelity streaming assets, or workflows where encoding time is secondary to bandwidth savings.
- Impact: This range offers the best compromise for offline encoding, enabling most of AV1’s advanced features without the extreme performance penalties of presets 0–2.
Presets 6 to 8: Balanced (Fast/Iterative)
- Speed: Fast.
- Quality: Moderate compression efficiency.
- Use Case: Quick drafts, daily video processing, or environments with limited CPU availability.
- Impact: The encoder disables some of the more complex analysis tools and uses heuristic approximations instead of exhaustive searches. This significantly boosts encoding speeds while maintaining acceptable visual quality, though file sizes will be larger compared to lower presets at equivalent quality targets.
Presets 9 to 10: Maximum Speed (Real-time & Testing)
- Speed: Very fast.
- Quality: Lowest compression efficiency.
- Use Case: Real-time streaming trials, pipeline testing, or rapid prototyping.
- Impact: At these levels, the encoder operates with minimal analysis, disabling the vast majority of AV1’s high-efficiency tools. While encoding speeds approach real-time thresholds, the visual quality for a given bitrate drops noticeably, and files will require a higher bitrate to avoid artifacting.
Summary of Preset Performance
| Preset Range | Relative Speed | Compression Efficiency | Recommended Use Case |
|---|---|---|---|
| 0 – 2 | Extremely Slow | Maximum | Archival / Quality-Critical |
| 3 – 5 | Moderate / Slow | High | Standard VOD Distribution |
| 6 – 8 | Fast | Moderate | Drafts / Fast Turnaround |
| 9 – 10 | Very Fast | Low | Testing / Live Streaming |