forge
Explore
Log in

Don't you dare go Hollow

The native BD arm honours EC_AV1_PYRAMID

Browse files at this commit

dbe9b292ab4fca2f136ada2a16a132cc86be163eAhmet Kaan GümüşParent: 81d8241
  • test
    • the native BD arm honours EC_AV1_PYRAMID
Show full message
test(av1): the native BD arm honours EC_AV1_PYRAMID

The native-crop arm called our_ladder directly, so every pyramid arm
measured at native was silently the flat encoder. It now takes the same
pyramid_from_env branch the default gate does, with the same three-way
check that path can make (ffmpeg vs our decoder, Y/U/V, display order)
and the per-level frame and byte census.
crates/ec-av1/src/encode.rsmodified+21 -1
@@ -10762,6 +10762,13 @@ mod tests {
10762 /// EC_AV1_INTRABC=1 ... same command # intra block copy10762 /// EC_AV1_INTRABC=1 ... same command # intra block copy
10763 /// EC_AV1_PAL_MAXCOLORS=256 ... same command # palette bound10763 /// EC_AV1_PAL_MAXCOLORS=256 ... same command # palette bound
10764 /// EC_AV1_TILES=1:1 EC_AV1_TILE_THREADS=4 ... # 2x2 tiles10764 /// EC_AV1_TILES=1:1 EC_AV1_TILE_THREADS=4 ... # 2x2 tiles
10765+ /// EC_AV1_PYRAMID=4:-16:8 ... same command # coding pyramid
10766+ ///
10767+ /// Under `EC_AV1_PYRAMID` this arm codes its ladder through the streaming
10768+ /// facade ([`our_ladder_pyramid`]), which exposes no per-packet
10769+ /// reconstruction: that path asserts ffmpeg's decode against our own
10770+ /// decoder on all three planes in display order, and prints the per-level
10771+ /// frame and byte census.
10765 ///10772 ///
10766 /// All three gate clips are rows by default. `EC_AV1_NATIVE_FILM=1`,10773 /// All three gate clips are rows by default. `EC_AV1_NATIVE_FILM=1`,
10767 /// `EC_AV1_NATIVE_FILM4K=1` and `EC_AV1_NATIVE_SCREEN=1` select a subset:10774 /// `EC_AV1_NATIVE_FILM4K=1` and `EC_AV1_NATIVE_SCREEN=1` select a subset:
@@ -10873,7 +10880,20 @@ mod tests {
10873 let _ = crate::tile::take_palette_uv_hits();10880 let _ = crate::tile::take_palette_uv_hits();
10874 let _ = crate::tile::take_intrabc_hits();10881 let _ = crate::tile::take_intrabc_hits();
10875 let _ = take_intrabc_search();10882 let _ = take_intrabc_search();
10876- let (ours, ours_wall) = our_ladder(name, &source, cw, ch, fctx);10883+ let (ours, ours_wall) = match pyramid_from_env() {
10884+ None => our_ladder(name, &source, cw, ch, fctx),
10885+ Some(pyramid) => {
10886+ let (ladder, wall, counts, bytes) =
10887+ our_ladder_pyramid(name, &source, cw, ch, pyramid);
10888+ eprintln!(
10889+ "{name}: pyramid {pyramid:?} -- frames key {} arf {} leaf {} \
10890+ show_existing {}; bytes key {} arf {} leaf {} show_existing {}",
10891+ counts[0], counts[1], counts[2], counts[3],
10892+ bytes[0], bytes[1], bytes[2], bytes[3],
10893+ );
10894+ (ladder, wall)
10895+ }
10896+ };
10877 // gate-blind-to-feature: what the screen tools actually did at10897 // gate-blind-to-feature: what the screen tools actually did at
10878 // native resolution, over this clip's four encodes.10898 // native resolution, over this clip's four encodes.
10879 let screen_on = SCREEN_FRAMES[1].load(std::sync::atomic::Ordering::Relaxed);10899 let screen_on = SCREEN_FRAMES[1].load(std::sync::atomic::Ordering::Relaxed);