edith_codecs
Clone
https://git.tahinli.com/Tahinli/edith_codecs.git
0 watching0 forksRust370.3 MiBddf43e8Tahinli2 months ago3186 commits
| 1 | #!/usr/bin/env bash |
| 2 | # Generate the ec-vp8 test fixtures (gitignored, like the rest of the |
| 3 | # workspace's fixtures/). Every vector is libvpx-encoded via ffmpeg; the |
| 4 | # decoder's witnesses compare its raw YUV output against ffmpeg's. |
| 5 | # |
| 6 | # Usage: scripts/gen_vp8_fixtures.sh [worktree-root] |
| 7 | |
| 8 | ROOT="" |
| 9 | OUT="/fixtures/vp8" |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 | # Key-frame vectors (M2): several sizes incl. non-multiple-of-16, several q. |
| 24 | |
| 25 | |
| 26 | |
| 27 | |
| 28 | |
| 29 | |
| 30 | |
| 31 | # Multi-frame GOP (M3): keyframe + interframes, golden/altref in play. |
| 32 | |
| 33 | |
| 34 | |
| 35 | |
| 36 | |
| 37 | |
| 38 | |
| 39 | # Larger short GOP with the simple loop filter via profile (version 1)? |
| 40 | # libvpx picks profile 0 normally; the version field is exercised through |
| 41 | # -profile:v 1 (simple filter, bilinear reconstruction). |
| 42 | |
| 43 | |
| 44 | |
| 45 | |
| 46 | || \ |
| 47 | |
| 48 | |
| 49 | # Multi-partition token partitions (M3): ffmpeg's libvpx wrapper has no |
| 50 | # token-part option, so this one vector comes from a locally built vpxenc |
| 51 | # (checked out at ~/.cache/vp8/libvpx-src; `./configure && make -j`). |
| 52 | VPXENC="/.cache/vp8/libvpx-src/vpxenc" |
| 53 | if [; then |
| 54 | |
| 55 | |
| 56 | |
| 57 | { |
| 58 | |
| 59 | |
| 60 | |
| 61 | |
| 62 | |
| 63 | |
| 64 | } | |
| 65 | |
| 66 | |
| 67 | |
| 68 | else |
| 69 | |
| 70 | fi |
| 71 | |
| 72 | # VP8-in-WebP still (same key-frame payload in a RIFF container). |
| 73 | |
| 74 | |
| 75 | |
| 76 | if ; then |
| 77 | |
| 78 | else |
| 79 | |
| 80 | |
| 81 | fi |
| 82 | |
| 83 | # Note on the three vectors below (review flag): every fixture in the set |
| 84 | # must come from THIS script — no ad-hoc leftovers. |
| 85 | # |
| 86 | # kf-16x16-black-q0: 1-MB all-black frame at q0 (the M2 "no ONE tokens" |
| 87 | # degenerate vector: exercises the zero-coefficient and overread paths). |
| 88 | |
| 89 | |
| 90 | # clip-obs-320x192: screen-content-shaped 320x192 clip. The original was |
| 91 | # an OBS window capture; the recorded reproducible stand-in is testsrc2 |
| 92 | # at the same size (same decoder paths: 20x12 MB grid, small-MV motion). |
| 93 | |
| 94 | |
| 95 | # altref-160x96: vpxenc --auto-alt-ref=1 in TWO passes (one-pass CQ/VBR |
| 96 | # never inserts hidden altrefs for this content) with --lag-in-frames, so |
| 97 | # libvpx emits HIDDEN alternate-reference frames (frame tag show_frame=0, |
| 98 | # currently 6 of 90 at decode indices 1,17,33,49,65,81). The witnesses |
| 99 | # census the tags and refuse a shown-only stream: the hidden-frame |
| 100 | # contract (no output, reference buffers still update, later frames |
| 101 | # reference the hidden altref) must be exercised. |
| 102 | |
| 103 | |
| 104 | |
| 105 | # Two passes need a seekable input (stdin cannot rewind for pass 2), so |
| 106 | # the y4m goes through a temp FILE, not a pipe. |
| 107 | { |
| 108 | | |
| 109 | |
| 110 | |
| 111 | |
| 112 | |
| 113 | |
| 114 | |
| 115 | } |
| 116 | |
| 117 | |
| 118 | |
| 119 | |
| 120 | |
| 121 | |
| 122 | |
| 123 |