forge
Explore
Log in

Don't you dare go Hollow

Drive the film-grain sweep with the repo aomenc and the supported-envelope recipe

Browse files at this commit

4da5dbf135004ba45746c659ab0026bb672cf977Ahmet Kaan GümüşParent: 84e41d9
  • test
    • drive the film-grain sweep with the repo aomenc and the supported-envelope recipe
Show full message
test(av1): drive the film-grain sweep with the repo aomenc and the supported-envelope recipe

The sweep probed bare `aomenc` on PATH (always absent) and so always
skipped; it now uses aomenc_path() like every other gate. The recipe
adopts the forwarding gate's constraint set so the streams stay inside
the decoder's supported envelope, with --tune-content=film as the one
flag under test. At 64x64 the streams now reach the GOLDEN_FRAME
refusal on this branch; the test goes green once the mvstack
extension-pass fix (lane-av1golden8) merges and unmasks GOLDEN.
crates/ec-av1/src/stream.rsmodified+47 -17
@@ -2453,17 +2453,11 @@ mod tests {
24532453 eprintln!("SKIP real_aomenc_film_grain_streams_decode_pixel_exact: no ffmpeg");
24542454 return;
24552455 }
2456- let have_aomenc = Command::new("aomenc")
2457- .arg("--help")
2458- .stdout(Stdio::null())
2459- .stderr(Stdio::null())
2460- .status()
2461- .is_ok_and(|s| s.success());
2462- if !have_aomenc {
2456+ if !have_aomenc() {
24632457 eprintln!("SKIP real_aomenc_film_grain_streams_decode_pixel_exact: no aomenc");
24642458 return;
24652459 }
2466- let (width, height) = (64usize, 48usize);
2460+ let (width, height) = (64usize, 64usize);
24672461 for seed in [1u64, 2, 3] {
24682462 let dir = std::env::temp_dir().join(format!(
24692463 "ec-av1-filmgrain-gate-{}-{seed}",
@@ -2483,21 +2477,57 @@ mod tests {
24832477 yuv.extend_from_slice(&card.v);
24842478 }
24852479 std::fs::write(&yuv_path, &yuv).unwrap();
2486- let status = Command::new("aomenc")
2480+ let status = Command::new(aomenc_path())
24872481 .args([
2488- "--width",
2489- &width.to_string(),
2490- "--height",
2491- &height.to_string(),
2482+ &format!("--width={width}"),
2483+ &format!("--height={height}"),
24922484 "--input-bit-depth=8",
24932485 "--bit-depth=8",
24942486 "--fps=25/1",
2495- "--limit",
2496- &frames.to_string(),
2497- "--tune-content=film",
2498- "--cpu-used=6",
2487+ &format!("--limit={frames}"),
2488+ // The full constraint set of the forwarding/golden gates,
2489+ // so the streams stay inside this decoder's supported
2490+ // envelope and the gate isolates grain synthesis alone;
2491+ // `--tune-content=film` is the one flag under test (it
2492+ // enables apply_grain).
2493+ "--codec=av1",
2494+ "--passes=1",
24992495 "--end-usage=q",
25002496 "--cq-level=32",
2497+ "--cpu-used=0",
2498+ "--lag-in-frames=0",
2499+ "--auto-alt-ref=0",
2500+ "--kf-max-dist=1000",
2501+ "--threads=1",
2502+ "--row-mt=0",
2503+ "--max-reference-frames=3",
2504+ "--reduced-reference-set=1",
2505+ "--enable-warped-motion=0",
2506+ "--enable-obmc=0",
2507+ "--enable-masked-comp=0",
2508+ "--enable-interintra-comp=0",
2509+ "--enable-dist-wtd-comp=0",
2510+ "--enable-diff-wtd-comp=0",
2511+ "--enable-onesided-comp=0",
2512+ "--enable-interintra-wedge=0",
2513+ "--enable-smooth-interintra=0",
2514+ "--enable-rect-partitions=0",
2515+ "--enable-ab-partitions=0",
2516+ "--enable-1to4-partitions=0",
2517+ "--enable-filter-intra=0",
2518+ "--enable-smooth-intra=0",
2519+ "--enable-paeth-intra=0",
2520+ "--enable-directional-intra=0",
2521+ "--enable-angle-delta=0",
2522+ "--enable-tx-size-search=0",
2523+ "--enable-cdef=0",
2524+ "--enable-restoration=0",
2525+ "--max-partition-size=32",
2526+ "--min-partition-size=32",
2527+ "--enable-palette=0",
2528+ "--enable-intrabc=0",
2529+ "--enable-cfl-intra=0",
2530+ "--tune-content=film",
25012531 "--obu",
25022532 "-o",
25032533 ])