Files
VoelinClient/docs
selikhovandClaude Opus 5.5 57fc25ab9e voelin-media: HEVC and AV1 levels and tiers that count the frame rate
VA-API's HEVC and AV1 encoders guessed their level themselves: FFmpeg's
AV1 guess reads the frame rate from `AVCodecContext.framerate`, which has
no AVOption and so was never set, and its HEVC guess ignores the rate. A
4K240 stream declared a level for 4K60, which a decoder that sizes itself
from the level may refuse.

The encoder now sets the level and tier from the stream's size, frame
rate and bitrate (H.265 Table A.8, AV1 A.3): the lowest level whose Main
tier holds the bitrate, else the lowest whose High tier does, else no
limits (HEVC 8.5, AV1 level 31) as FFmpeg does. 4K60 at 60 Mbit/s is 5.2
Main, 4K240 and 8K60 6.1. Only for VA-API, whose options take
`general_level_idc` and `seq_level_idx`; other wrappers count levels
differently. The rate-control buffer is clamped to what its int holds, so
a typed bitrate above 1 Gbit/s no longer fails the open.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 03:57:53 +03:00
..