forge
Explore
Log in

Don't you dare go Hollow

vp9refsetup: regenerate the odd fixture from the current patcher; narrow the ffmpeg claim

Browse files at this commit

14264898624d8b83d590f6e345bba0c3a76aed7aAhmet Kaan GümüşParent: 2251b71
- tests/data/scaledref_odd.ivf now reproduces from
  gen_scaledref.c + patch_kf_size.py <in> <out> 1279 719 (sha256
  af289a0f8dd91bfa854adeac1814dc77644ad87b9df0af884d33abaae2595413); the old
  bytes predated the patcher's IVF container-header rewrite (3 bytes).
  Still byte-identical to libvpx (drv_pix3 vs ours, 4490801 bytes, cmp).
- the "ffmpeg SIGSEGVs on a changing filter output" wording is narrowed to the
  verified scope: the scale=...:eval=frame route exits 139 with a 0-byte file,
  and independently ffmpeg's output size is locked to the first decoded frame.
crates/ec-vp9/tests/data/scaledref_odd.ivfmodified+0 -0

Binary file changed

crates/ec-vp9/tests/scaledref_exact.rsmodified+6 -4
@@ -10,12 +10,14 @@
10 //! The fixtures are committed under `tests/data/` because no ffmpeg10 //! The fixtures are committed under `tests/data/` because no ffmpeg
11 //! invocation can produce a size change: libvpx's encoder emits one only11 //! invocation can produce a size change: libvpx's encoder emits one only
12 //! through its rate-control resize path (ffmpeg exposes neither12 //! through its rate-control resize path (ffmpeg exposes neither
13-//! `rc_resize_allowed` nor SVC and crashes outright on a changing filter13+//! `rc_resize_allowed` nor SVC; its `scale=...:eval=frame` route exits 139
14-//! output), and a hand-spliced explicit-size inter frame trips libvpx's own14+//! with a 0-byte file), and a hand-spliced explicit-size inter frame trips
15-//! header reparsing. The generator is recorded in15+//! libvpx's own header reparsing. The generator is recorded in
16 //! `lanes/vp9refsetup.report.md`: a 1280x720 one-pass CBR encode at 200 kbps,16 //! `lanes/vp9refsetup.report.md`: a 1280x720 one-pass CBR encode at 200 kbps,
17 //! whose `vp9_resize_one_pass_cbr` downscales frame 1 to 640x360 against the17 //! whose `vp9_resize_one_pass_cbr` downscales frame 1 to 640x360 against the
18-//! keyframe.18+//! keyframe. `scaledref_odd.ivf` is that same file through
19+//! `$HOME/.cache/vp9pix/patch_kf_size.py <in> <out> 1279 719` (which rewrites
20+//! the IVF container size too).
19 //!21 //!
20 //! Oracle caveat: ffmpeg locks its rawvideo output size to the FIRST decoded22 //! Oracle caveat: ffmpeg locks its rawvideo output size to the FIRST decoded
21 //! frame's, so a two-size stream cannot be dumped in one pass. Frame 0 is23 //! frame's, so a two-size stream cannot be dumped in one pass. Frame 0 is
lanes/vp9refsetup.report.mdmodified+8 -4
@@ -64,9 +64,12 @@ None of these can be produced by an ffmpeg invocation:
64 byte (`cmp` verified). 11 frames: keyframe, hidden intra-only twin, 9 inter.64 byte (`cmp` verified). 11 frames: keyframe, hidden intra-only twin, 9 inter.
65 * **size change**: libvpx's encoder resizes only through rate control65 * **size change**: libvpx's encoder resizes only through rate control
66 (`vp9_resize_one_pass_cbr`, `vp9_ratectrl.c:2728`); ffmpeg exposes neither66 (`vp9_resize_one_pass_cbr`, `vp9_ratectrl.c:2728`); ffmpeg exposes neither
67- `rc_resize_allowed` nor SVC, and its filtergraph SIGSEGVs (exit 139) on a67+ `rc_resize_allowed` nor SVC. Its `scale=...:eval=frame` route into ivf/webm
68- changing output size. Generated by `lanes/vp9refsetup/gen_scaledref.c`68+ exits 139 with a 0-byte file (ffmpeg 8.1.2), and independently ffmpeg's
69- (links the pristine libvpx 1.15.0 encoder):69+ rawvideo/muxer output size is locked to the first decoded frame (see the
70+ oracle caveat), so it cannot express the change either way. Generated by
71+ `lanes/vp9refsetup/gen_scaledref.c` (links the pristine libvpx 1.15.0
72+ encoder):
70 ```73 ```
71 gcc -I<libvpx> -I<libvpx>/vpx gen_scaledref.c <libvpx>/libvpx.a -o enc -lm -lpthread74 gcc -I<libvpx> -I<libvpx>/vpx gen_scaledref.c <libvpx>/libvpx.a -o enc -lm -lpthread
72 ./enc scaledref.ivf 1280 720 10 200 # one-pass CBR, 200 kbps, lag 075 ./enc scaledref.ivf 1280 720 10 200 # one-pass CBR, 200 kbps, lag 0
@@ -78,7 +81,8 @@ None of these can be produced by an ffmpeg invocation:
78 size fields patched 1280x720 -> 1279x719 (mi-grid invariant, so the tile data81 size fields patched 1280x720 -> 1279x719 (mi-grid invariant, so the tile data
79 stays valid) — the reference is then an odd coded extent and its chroma crop82 stays valid) — the reference is then an odd coded extent and its chroma crop
80 ceils. Patch with the existing83 ceils. Patch with the existing
81- `$HOME/.cache/vp9pix/patch_kf_size.py <in> <out> 1279 719`.84+ `$HOME/.cache/vp9pix/patch_kf_size.py <in> <out> 1279 719`, which rewrites the
85+ IVF container size as well (`sha256 af289a0f8dd91bfa854adeac1814dc77644ad87b9df0af884d33abaae2595413`).
82 86
83 ## Gates87 ## Gates
84 88