Commits
Commits on
a646d8c4ff4dfef7e5c7abada8b8702a5e893c812026-09-07
fix(av1): the third pyramid level only inside a run that holds more than one mini-GOPAhmet Kaan Gümüş · 0061431
fix(av1): the third pyramid level only inside a run that holds more than one mini-GOP A 12-picture GOP is one absorbed group of 11 and pays 2.8 BD points against libaom on film B for a second hidden frame at every offset measured, while a 48-picture GOP gains 6.0. Gated on gop > mini_gop * 1.5, so the 12-frame gate codes byte for byte what it coded before (+43.9/+15.6, +68.4/+38.2).
feat(av1): the three-level pyramid ships by default (mid ARF at -8)Ahmet Kaan Gümüş · 7aedb7b
feat(av1): the three-level pyramid ships by default (mid ARF at -8) Long-GOP sweep against a control arm on this head (lanes/pyr5.sweep.txt): film A +55.2/+12.8 -> +52.1/+11.7, film B +151.3/+47.4 -> +145.3/+45.0 vs libaom cpu-used 6 / rav1e speed 6. Byte pins are unmoved (their 4-picture clip codes one group of 3, which has no room for a mid level).
docs(av1): the 48-frame long-GOP census -- the gap is the key-frame allocation and the missing hidden levels, not the leavesAhmet Kaan Gümüş · 9069d2aBrowse files
feat(av1): a third pyramid level -- a hidden mid ARF inside each mini-GOPAhmet Kaan Gümüş · 5502480
feat(av1): a third pyramid level -- a hidden mid ARF inside each mini-GOP Pyramid gains mid_q_offset (EC_AV1_PYRAMID=<mini_gop>:<arf>:<leaf>[:<mid>], 'off' for the two-level shape). A group of at least four codes a second hidden frame at the middle of its leaf run, off the anchor with the top ARF as its backward reference; the leaves before it name it as ALTREF and the first leaf after it starts its chain from it. Default stays two-level until the long-GOP sweep decides.
Merge branch 'lane-gopad' (6aef216e): the mini-GOP layout absorbs a short tail group; 12-frame film A +51.2/+21.4 -> +43.9/+15.6, film B +91.0/+53.5 -> +68.4/+38.2, 48-frame streams byte-identicalAhmet Kaan Gümüş · 8f9d371Browse files
feat(av1): a GOP-length-aware mini-GOP layout -- a short tail group is absorbedAhmet Kaan Gümüş · 52506a7
feat(av1): a GOP-length-aware mini-GOP layout -- a short tail group is absorbed
`Av1Encoder::encode_frames` closed every mini-GOP at `Pyramid::mini_gop`
flat, so a run that is not a multiple of it left a SHORT TAIL group: 12
pictures under mini_gop 8 coded 8 + 3, and lane-pyr4 measured that tail as
the whole disagreement between the two BD gates (the 12-frame gate wanted
16:-24:16, the 48-frame gate 8:-32:16).
`group_target()` now sizes the group being collected from the pictures left
before the next key frame -- both entry points know it (`encode_sequence`
sets gop = pictures.len(), the facade has its config) -- and absorbs a tail
shorter than half a group into the group before it.
12-frame gate at 8:-32:16, film A / film B vs libaom / rav1e:
fixed 8 + 3 +51.2 / +21.4 +91.0 / +53.5
absorb -> 11 +43.9 / +15.6 +68.4 / +38.2 (bars rows improve too)
48-frame gate: 47 inter pictures are 8 x 5 + 7 under BOTH rules, and the
control arm confirms it byte for byte -- all eight ladder points identical,
+55.2 / +12.8 and +151.3 / +47.4 either way.
The balanced-split variant (equal groups <= mini_gop, 6 + 5 at gop 12) was
measured and is worse on every row; a group-length-scaled ARF offset was
dropped unbuilt, since the absorbed group at arf -32 already beats the -24
the 12-frame gate used to prefer. Table and logs: lanes/gopad.sweep.txt.
`EC_AV1_GOP_LAYOUT=fixed` restores the old rule for an A/B.Merge branch 'lane-pyr4' (e0a8b8a2): a 48-frame long-GOP film gate; the default pyramid is 8:-32:16, the long-GOP optimumAhmet Kaan Gümüş · d248e08
Merge branch 'lane-pyr4' (e0a8b8a2): a 48-frame long-GOP film gate; the default pyramid is 8:-32:16, the long-GOP optimum Long GOP (48 pictures, gop 48): film A +67.4/+21.0 -> +55.7/+13.5, film B +165.5/+57.6 -> +165.1/+56.6 vs libaom cpu-used 6 / rav1e speed 6. The 12-frame gate prefers 16:-24:16, so the optimum is GOP-length dependent; long GOP governs because that is what the editor exports. Pins re-taken on the merged tree with the 64x64 skip root: 8446 / 28548.
feat(av1): the coding pyramid decided on a long GOP -- Pyramid::default 16:-24:16 -> 8:-32:16Ahmet Kaan Gümüş · 0d3b9a0
feat(av1): the coding pyramid decided on a long GOP -- Pyramid::default 16:-24:16 -> 8:-32:16 The shipped shape came off bd_rate_screen_native, which codes 12 frames with gop = 12; a mini-GOP is cut at every key frame, so any mini_gop over 12 codes the SAME stream there and the 16 was really "one hidden ARF per 12-picture GOP". On the new long-GOP arm (48 pictures, gop 48, the two real films, vs libaom cpu-used 6 and rav1e speed 6 at -g 48) a real 16- or 32-picture group is WORSE than an 8-picture one, and ARF -32 is an interior optimum (-40 turns back). 8:-32:16 takes 11.7 / 7.5 points off film A and 0.4 / 1.0 off film B against 16:-24:16 -- all four columns down. The price is stated in Pyramid::default and lanes/pyr4.sweep.txt: at a 12-frame GOP the new shape is 7.0 / 5.7 (film A) and 20.5 / 18.3 (film B) worse, because the best shape depends on GOP length and the long GOP is what the editor exports. Pins re-taken: 8076 -> 8755 at q=150, 27585 -> 28637 at q=60.
Merge branch 'lane-b64' (52edbfd2): a 64x64 skip root in the inter search, on at presets 0..3Ahmet Kaan Gümüş · 473ca5c
Merge branch 'lane-b64' (52edbfd2): a 64x64 skip root in the inter search, on at presets 0..3 Film A +44.2/+15.7 -> +43.0/+15.0, film B +70.5/+35.2 -> +64.7/+34.0, screen +48.2/-16.4 -> +33.4/-23.8 vs libaom cpu-used 6 / rav1e speed 6; wall down on four rows. Pins 7291 / 27466. Non-skip and intra 64 roots wait on a forward 64-point transform.
perf(av1): the 64x64 root ships at presets 0..=3, off from 4Ahmet Kaan Gümüş · 71bf2a8
perf(av1): the 64x64 root ships at presets 0..=3, off from 4 Measured on the native gate at EC_AV1_SPEED=6 (two arms side by side): ON costs film A +55.1/+24.8 -> +64.5/+37.5 and film B +91.5/+53.4 -> +114.6/+71.5 for -16%/-36% wall, because the trial's early-out rides SPLIT_RD -- at 0.5 a superblock is taken whole with its quadrants never searched and film B's q150 point drops 1.2 dB. Presets 1..=3 keep SPLIT_RD at 0.125, so they get the early-out that was measured good.
test(av1): re-pin the encoder's own streams for the 64x64 rootAhmet Kaan Gümüş · be3d4bc
test(av1): re-pin the encoder's own streams for the 64x64 root 8076 -> 7291 bytes at q=150 and 27585 -> 27466 at q=60 over the four-frame pin clip. The native gate keeps the lever: every row improves on both columns (film A +44.2/+15.7 -> +43.0/+15.0, film B +70.5/+35.2 -> +64.7/+34.0, screen +48.2/-16.4 -> +33.4/-23.8, bars 2160p +20.7/-3.8 -> +13.3/-9.9). EC_AV1_B64=0 restores the old pins byte for byte.
feat(av1): a 64x64 PARTITION_NONE skip root for the inter searchAhmet Kaan Gümüş · 5bcc6a5
feat(av1): a 64x64 PARTITION_NONE skip root for the inter search The census (lanes/census-filmB.md) found rav1e speed 6 coding 45.2% of its blocks at 64x64 -- 73.8% of its leaf blocks, 99.2% of them skip -- while every block this encoder wrote was a 32x32 quadrant or smaller, which put our mode+mv+partition+tx_size spend at 162,669 bits against rav1e's 61,988. The search now offers the whole superblock as one 64x64 block coded SKIP (NEAREST/NEAR/GLOBAL/NEW single-ref, priced through the same symbol_bits path) against the four quadrants, and takes it outright when its per-pixel cost is already under the split-RD threshold -- where the lever saves wall rather than spending it. Skip-only: a 64x64 residual needs a forward TX_64X64 the encoder does not have, and the writer refuses any other shape. EC_AV1_B64=0 switches it off; speed::B64_ROOT is the preset column.
test(av1): a long-GOP native BD arm -- 48 frames, gop 48, film rows onlyAhmet Kaan Gümüş · c58bcaa
test(av1): a long-GOP native BD arm -- 48 frames, gop 48, film rows only bd_rate_screen_native codes 12 frames with gop=12 and encode_frames cuts a mini-GOP at every key frame, so any Pyramid::mini_gop over 12 codes the SAME stream there: the shipped 16 was measured as one hidden ARF per 12-picture GOP, never as a real 16-picture group (class instrument-at-bound). bd_rate_film_long_gop reuses native_gate_clips and the three-way exact decode through a shared driver native_bd_arm(label, frames, films_only); ffmpeg gets -g 48, which both reference wrappers honour (measured: 96 frames at -g 48 code 2 key frames under librav1e and libaom-av1 alike).
Merge branch 'lane-census' (eee03662): decode-side syntax and bit census (EC_AV1_BITCENSUS), and the film B answerAhmet Kaan Gümüş · 09cb0af
Merge branch 'lane-census' (eee03662): decode-side syntax and bit census (EC_AV1_BITCENSUS), and the film B answer Bits are charged per CDF table by address range, so every tool is accounted without call-site labels; census total tracks the tile payload to 0.03%. Film B at matched PSNR: the whole gap is inter frames (leaves 11.5x rav1e's bytes); no 64x64 blocks or transforms are coded (46% of the gap); rav1e's q ladder spreads 61 steps against our 24.
Merge branch 'lane-pyr3' (fb84d37d): the frame pyramid re-swept on real film; default 16:-24:16Ahmet Kaan Gümüş · 29892fb
Merge branch 'lane-pyr3' (fb84d37d): the frame pyramid re-swept on real film; default 16:-24:16 Film A +52.8/+23.3 -> +44.2/+15.7, film B +81.0/+46.1 -> +70.5/+35.2 vs libaom cpu-used 6 / rav1e speed 6; screen byte-identical. Pins 8076 / 27585. The 12-frame gate cannot separate mini_gop 16 from 12; a longer GOP gate follows.
perf(av1): re-sweep the coding pyramid on real film -- 16:-24:16Ahmet Kaan Gümüş · 92428b3
perf(av1): re-sweep the coding pyramid on real film -- 16:-24:16 The shipped 4:-16:8 was chosen when the BD gate's "film" rows were still testsrc2 colour bars, and CfL, the luma angle deltas, filter intra, the propagating tpl map and the rate-loop step have all landed since, so the shape was unswept on real content (class `unswept decision constants`). Swept through the gate's own EC_AV1_PYRAMID knob on the two real film rows of encode::tests::bd_rate_screen_native: the mini-GOP axis at the shipped offsets, then both offset axes at the best mini-GOP, then the joint corners (21 arms, table in Pyramid::default and lanes/pyr3.sweep.txt). 16:-24:16 takes 8.6 / 7.6 BD points off film A and 10.5 / 10.9 off film B against 4:-16:8 (vs libaom / vs rav1e); the screen row is byte-identical in every arm because the content gate codes it flat. Leaf +16 was the swept range's edge and still improving on film A, so two arms past it were run: film B turns back up at +20, so +16 is where both films are minimal. Pins re-taken: encode_sequence codes the 4-picture pin clip as one truncated group now (hidden ALTREF at q-24, three leaves at q+16), 7373 -> 8076 at q=150 and 27074 -> 27585 at q=60; EC_AV1_PYRAMID=4:-16:8 restores them.
docs(av1): the census table's tx_type/tx_size cells, read off the runs instead of roundedAhmet Kaan Gümüş · 8b8a9c8Browse files
feat(av1): a decode-side syntax census, and the film B vs rav1e table it producedAhmet Kaan Gümüş · 373b6a2
feat(av1): a decode-side syntax census, and the film B vs rav1e table it produced The BD gate says our stream is bigger; it never says which syntax it is bigger in. This adds a per-CDF-table bit accountant to the symbol decoder (EC_AV1_BITCENSUS=1, one relaxed load per symbol when off) plus block, tx, mv, mode and frame-header funnels, and an examples/syntax_census.rs that prints one table per stream -- so our stream and rav1e's are measured by the same reader. lanes/census-filmB.md holds the answer for film B at matched PSNR: the whole gap is in the inter frames (our key frame is the smaller and the worse one), 75% of it in the leaves, and the three mechanisms are the flat pyramid q ladder, the missing 64x64 blocks and transforms, and a 52.5% vs 84.8% skip share.
Merge branch 'lane-fitu' (5a90cf79): per-transform-unit filter intra in the tx-depth search, armed on screen frames; film rows byte-identical, screen +49.2/-16.0 -> +48.2/-16.4Ahmet Kaan Gümüş · c1ee326Browse files
feat(av1): filter intra predicts per transform unit, depths searched on screen framesAhmet Kaan Gümüş · 235add9
feat(av1): filter intra predicts per transform unit, depths searched on screen frames The filter-intra candidate used to be priced at tx_depth 0 only: a block whose ordinary intra winner wanted a split transform was compared against a handicapped filter arm, and only 19-44% of intra blocks code depth 0. `Plane::code_tx_depth` now takes the block's `filter_intra_mode` and predicts each transform unit recursively off the units before it -- what decode.rs already does per unit -- so the arm can be priced at every depth through the same pricer, neighbour context and `fimode_to_intradir` tx row. Measured on the native BD table: searching the depths on EVERY frame moves screen -1.0/-0.4 and the bars rows -0.4/-0.7, but leaves film A flat and film B +0.1/+0.5 WORSE at +30..35% encoder wall -- the extra filter blocks are a locally cheaper reconstruction the film rows then predict from. So the depth search is armed on screen frames only: every non-screen frame keeps the depth-0-only arm and codes byte-identical streams (film A/B and both bars rows reproduce the baseline table byte for byte), while the screen row goes +49.2 -> +48.2 vs libaom and -16.0 -> -16.4 vs rav1e for +21% wall on that row.
Merge branch 'lane-av1fast' (d3c88c3d): a speed preset axis 0..=10 for the software encoder, preset 0 the shipped searchAhmet Kaan Gümüş · db67894
Merge branch 'lane-av1fast' (d3c88c3d): a speed preset axis 0..=10 for the software encoder, preset 0 the shipped search Levers priced on film A; compound is the costliest tool to drop and warp, loop restoration and the tpl map are free. The Pareto against rav1e and SVT-AV1 fast presets is recorded in speed.rs: pruning alone does not reach real time. Filter intra ships as a preset-0-only lever.
feat(av1): filter intra is a speed lever -- on at preset 0, off above itAhmet Kaan Gümüş · a14fe08
feat(av1): filter intra is a speed lever -- on at preset 0, off above it
Rebased onto main's filter-intra candidate, then priced it the way every
other lever in speed.rs was priced. Two sequential arms on film A native
at speed 3 (lanes/fi-s3-{on,off}.log): ON +54.6/+24.3 BD at 43.1s over a
13.7s rav1e anchor, OFF +55.1/+24.7 at 39.6s over 14.2s -- 0.5 BD points
for 12.8% wall, 0.039 points per 1% wall, between the levers speed 3
already cuts (CfL + angle, 0.031) and the next one it keeps (coefficient
breakout, 0.041). A preset whose purpose is wall does not spend it there,
so FILTER_INTRA is true at index 0 only; EC_AV1_FILTER_INTRA still wins.
filter_intra_on() also loses its OnceLock cache for the LazyLock-env +
speed::at shape every other lever uses -- the preset is set at encoder
construction, so a cached value would have frozen the first speed.docs(av1): the preset Pareto against rav1e, libaom and SVT-AV1Ahmet Kaan Gümüş · 4ff71fa
docs(av1): the preset Pareto against rav1e, libaom and SVT-AV1 Native-gate film and screen rows per preset, threaded fps at 1920x1080 and 3840x1608 (4x2 tiles, 8 threads), and a 4-point ladder for every reference preset this ffmpeg can run (its libaom wrapper caps cpu-used at 8, and cpu-used 6 and 8 code byte-identical ladders here). The keep rule fails on film at every preset: rav1e reaches our speed-10 wall at +16.9 BD where we are at +104.9.
test(av1): the shipped presets decode sample-exact through both decodersAhmet Kaan Gümüş · e66bbaa
test(av1): the shipped presets decode sample-exact through both decoders Re-adds the preset gate the crate-wide rustfmt revert took with it, and records the measured lever table and preset rows in speed.rs's own docs.
feat(av1): compose the speed presets from a measured per-lever tableAhmet Kaan Gümüş · ed24ce6
feat(av1): compose the speed presets from a measured per-lever table One native-gate ablation per lever on film A at speed 0 (lanes/ab-*.log): warp, loop restoration and the tpl map are free or better on real film (-0.2/-0.2/0.0 BD) and the 8x8 split is 59% of the wall for +0.6, while compound costs +30.5 BD and leaf compound +9.6 -- so the ladder switches them off in that order, not in the order the old bars-fixture sweeps suggested. The table and the end-to-end preset rows are in speed.rs.
feat(av1): a speed preset axis (0..=10), preset 0 the search we shipAhmet Kaan Gümüş · 597c1a3
feat(av1): a speed preset axis (0..=10), preset 0 the search we ship
Every search lever this crate already has an EC_AV1_* knob for reads its
default from a per-speed table in the new `speed` module, indexed by one
process-global preset (`Av1Encoder::with_speed`, `EC_AV1_SPEED`). Index 0
of every table IS the shipped constant, so preset 0 is byte-identical by
construction; `speed::levers` names what each preset switches off, and
ec-bench codes one row per preset {0,3,6,10}.Merge branch 'lane-fintra' (88c5ef0f): filter intra as an intra-search candidate, default on; enable_filter_intra threaded through every raw decode of the encoder's own tilesAhmet Kaan Gümüş · 9b5376d
Merge branch 'lane-fintra' (88c5ef0f): filter intra as an intra-search candidate, default on; enable_filter_intra threaded through every raw decode of the encoder's own tiles Native table: film A +53.2/+23.4 -> +52.8/+23.3, film B +81.5/+46.5 -> +81.0/+46.1, screen flat. Pins 7373 / 27074. Six gate decodes passed a literal false for the header bit (stale-header class, swept).
docs(av1): name the filter-intra tx_depth ceiling at the candidateAhmet Kaan Gümüş · 48bcb5cBrowse files
chore(av1): the filter-intra fire counter is a test-only readerAhmet Kaan Gümüş · eb8b60aBrowse files
test(ogg): drop a redundant pair of parentheses left by the fixture-selection sweepAhmet Kaan Gümüş · f60b302Browse files
Merge branch 'lane-nbpub' (95f1d1e0): EC_AV1_NORECON measurement rung; the encoder's first decode is 4.3% of the 4K wall and 94% of it is parse, so publishing the reconstruction cannot remove itAhmet Kaan Gümüş · 6dfe455Browse files
test(av1): mode ablations opt out of filter intra; re-pin the encoder's own streamsAhmet Kaan Gümüş · 0b03c13
test(av1): mode ablations opt out of filter intra; re-pin the encoder's own streams
test(av1): a filter-intra key frame decodes pixel-exact through ffmpeg; native gate prints the fire rateAhmet Kaan Gümüş · 24771c9
test(av1): a filter-intra key frame decodes pixel-exact through ffmpeg; native gate prints the fire rate
perf(av1): measure the encoder's first decode -- 94% of it is parse, not reconstructionAhmet Kaan Gümüş · 591f575
perf(av1): measure the encoder's first decode -- 94% of it is parse, not reconstruction The encoder decodes its own written tiles once per frame to reach the reconstruction and the per-mi neighbour state the filter search reads (`par::S_FIRST`). The plan for removing it was to hand the decoder the encoder's own reconstruction, which the writer already holds. `EC_AV1_NORECON=1` drops every recorded pixel write in `exec_op` and leaves the entropy parse and the neighbour bookkeeping alone. At 3840x1608 (4 frames, 4x2 tiles, 8 tile threads) the stage moves 150 ms -> 141 ms: the reconstruction is 6% of it, the parse and the per-mi grids are the other 94%. So the planes are not the lever -- only a writer-side publisher of the filter-relevant `decode::Neighbours` grids (blk_grid, tx/tx_h, uv_tx/uv_tx_h, ref_grid, delta_lf_grid), which skips the parse entirely, can remove the stage. Measurement only; the flag is off by default and the encoder's own streams are byte-identical to their pins.
feat(av1): filter intra as an intra-search candidateAhmet Kaan Gümüş · b978eaa
feat(av1): filter intra as an intra-search candidate Threads the sequence header's `enable_filter_intra` through the raw inter tile decode entry points and the gates that decode the encoder's own tiles (stale-header class: five hard-coded `false`s), writes `filter_intra_mode_info` at all five intra write sites between the palette colour lists and the colour-index maps, and offers the five recursive filter-intra modes as RD-priced candidates after the mode/tx-depth/palette searches. `EC_AV1_FILTER_INTRA=0` restores the previous streams.
Merge branch 'lane-hwwt' (a191a35b): test fixture selection matched the whole checkout path, so a worktree named after a codec fed foreign fixtures to it; swept to ec-image/ec-ogg/ec-mp4Ahmet Kaan Gümüş · c9c94fcBrowse files
fix(tests): fixture selection matched the checkout path, not the file nameAhmet Kaan Gümüş · a8b31aa
fix(tests): fixture selection matched the checkout path, not the file name
The GPU decode tests picked their fixtures with
p.to_string_lossy().contains(codec), which sees the whole path. In a
worktree called edith_codecs-av1fast every .ivf matched "av1", so the
VP9 streams were handed to the AV1 decoder and came back as
Stream(Corrupt { context: "AV1 obu_forbidden_bit is set" }) after the
five real AV1 fixtures had decoded frame-exactly. Same shape swept in
ec-image (lossless/lossy/animated), ec-ogg and ec-mp4.Merge branch 'lane-hwav1p010' (bc5dfe9c): 10-bit hardware AV1 encode and CBR/VBR/QVBR rate controlAhmet Kaan Gümüş · 6c19568
Merge branch 'lane-hwav1p010' (bc5dfe9c): 10-bit hardware AV1 encode and CBR/VBR/QVBR rate control P010 surfaces with high_bitdepth in the sequence header; film B's native 10-bit crop agrees frame for frame between ec-av1 and libdav1d. The rate control attribute must be set at config creation, and the HRD buffer is one rate window three-quarters full (two half-full windows undershot by 20%).
test(ec-hw): exercise the two 10-bit refusals; bench 10-bit row off the black leaderAhmet Kaan Gümüş · b19cdc4
test(ec-hw): exercise the two 10-bit refusals; bench 10-bit row off the black leader The refusals are claims, so they are driven: a 10-bit HEVC config must fail to build (High and Main are 8-bit profiles) and 8-bit pixels handed to a 10-bit encoder must be refused. ec-bench's 10-bit row seeks a minute in -- frame 0 of a film is its black leader, which coded to 1 kB for 30 frames and benchmarked nothing (101 kB now).
build: raise the test-thread stack in the repo config; the 48-frame rate-target test overflowed 2 MB in debug buildsAhmet Kaan Gümüş · 06e0c1f
build: raise the test-thread stack in the repo config; the 48-frame rate-target test overflowed 2 MB in debug builds
feat(ec-hw): 10-bit BD row, 10-bit fps, ec-bench 10-bit row, docsAhmet Kaan Gümüş · ebea85e
feat(ec-hw): 10-bit BD row, 10-bit fps, ec-bench 10-bit row, docs The 10-bit BD row is film B's own 1920x1024 native crop, every arm in the 10-bit domain: hw AV1 10-bit is +36.7% BD-rate against librav1e speed 6 10-bit and +52.9% against libaom cpu-used 6 10-bit, with all three ladders asserted monotone. av1_encode_speed gains a 3840x1608 10-bit row, and ec-bench an 'ec-hw av1 10-bit' encode row that skips as a row without a VA device.
feat(ec-hw): CBR, VBR and QVBR rate control for hardware encodeAhmet Kaan Gümüş · 5fcd26f
feat(ec-hw): CBR, VBR and QVBR rate control for hardware encode The AV1 path had only ever measured CQP because the VA config was created without a VAConfigAttribRateControl at all: a driver configured for CQP ignores a bitrate handed to it afterwards. The attribute is now set from the mode, and VariableBitrate / Qvbr join the enum (VBR sends the ask as a 1.5x ceiling at 66%, QVBR sends quality_factor, which needed a field in VAEncMiscParameterRateControl's payload). Root cause of a 20% CBR undershoot, found by comparing with ffmpeg's own av1_vaapi on the same clip (it undershot 8%): the HRD buffer was two rate windows starting half full. One window, three quarters full -- what ffmpeg asks for -- brings CBR to -4.2/-5.1/-7.9% and VBR to +1.0/-3.8/-6.9% at 2/6/12 Mbps on film A 1080p30. Gate av1_encode_rate_control_lands prints the whole table (pix_fmt, mode, target, delivered, PSNR) and asserts CBR within 15%, VBR within 25%, PSNR monotone in the target, and QVBR under its ceiling.
feat(ec-hw): 10-bit AV1 hardware encodeAhmet Kaan Gümüş · 98dcdcf
feat(ec-hw): 10-bit AV1 hardware encode His whole AV1 library is yuv420p10le, so an 8-bit-only hardware encoder does not serve his files. EncoderConfig gains a bit_depth (8, or 10 for AV1: H264High and HEVCMain are 8-bit profiles by definition, which is a fact about the profiles this crate configures, not a driver refusal), a 10-bit encoder allocates P010 surfaces, uploads through encode_16, sets bit_depth_minus8 = 2 in the sequence parameters and high_bitdepth in the sequence header OBU it packs. encode_frame now passes a 10-bit decoded surface straight through when the encoder is 10-bit too, and VPPs only when the depths or the sizes differ. Gate av1_10bit_encode_agrees_between_two_decoders on film B's own 1920x1024 native crop: ec-av1 and libdav1d agree sample for sample on all 10 frames, ffprobe reads yuv420p10le out of the sequence header, decoded peak luma 610 (> 255), worst frame 48.09 dB from the source in the 10-bit domain.
Merge branch 'lane-hwav1enc' (eda549f4): VAAPI AV1 hardware encode, on by default, agreed by two decodersAhmet Kaan Gümüş · cb7efaf
Merge branch 'lane-hwav1enc' (eda549f4): VAAPI AV1 hardware encode, on by default, agreed by two decoders radeonsi parses the app-written sequence and frame header OBUs and writes its own; the coded buffer carries no temporal delimiter, so one is prepended per frame. Film A reads +29.2% vs librav1e speed 6 at 122.8 fps (1080p) and 48.2 fps at 3840x1608.
test(ec-hw): a hardware AV1 quality row against librav1e and libaomAhmet Kaan Gümüş · c1c4cb5
test(ec-hw): a hardware AV1 quality row against librav1e and libaom Four quantisers on a 1080p crop of a film and of a screen capture from the real-library manifest, PSNR from ffmpeg, BD-rate over the shared quality range. The number is printed, not asserted -- a fixed-function encoder is not a search -- but the ladders are asserted monotone.
Merge branch 'lane-av1libdet' (3b42e286): the screen detector probed against the whole real library; zero camera rows fire, constants unchangedAhmet Kaan Gümüş · ed9607d
Merge branch 'lane-av1libdet' (3b42e286): the screen detector probed against the whole real library; zero camera rows fire, constants unchanged The premise that a real film of his was classified as screen was false: the ec-bench "real film" h264 source is a desktop recording, so the flat verdict was right. probe_screen_library walks the manifest at three offsets.
feat(ec-hw): AV1 encode on by default, and an ec-bench hardware rowAhmet Kaan Gümüş · 24f4e5c
feat(ec-hw): AV1 encode on by default, and an ec-bench hardware row The opt-in existed because a 2026-08-14 submission crashed the GPU; on mesa 26.1.8 the path encodes streams two decoders agree on, so the refusal goes rather than outliving its evidence. ec-bench gains an 'ec-hw av1 encode' row that skips as a row when there is no VA device.