interplane.Get Omega
Read in your language

omega-mp4

omega-mp4: ovideo, an MP4 reader written in Omega (Apache-2.0)

Brought by drakestapleton

branch main Branches Tags History

omega-mp4 / corpus / SOURCES.txt

53 lines · 5642 bytes Raw Blame History
1omega-mp4 corpus. Every file was generated on the Spark (Linux AArch64) with the installed
2ffmpeg 6.1.1-3ubuntu5+esm13 from its own synthetic sources (lavfi testsrc, testsrc2 and sine) or
3from the cue text corpus/src/cues.srt written for this corpus, or by tests/mkcases.om from those
4files. Nothing was downloaded. Each command ran from the repository root with these variables:
5 F="-nostdin -hide_banner -v error -y"; O="-map_metadata -1 -fflags +bitexact -flags:v +bitexact -flags:a +bitexact"
6 X="-c:v libx264 -preset veryfast -threads 1"; A="-c:a aac -aac_pns 0"
7Two runs of all eleven commands gave byte-identical files (sha256 compared, 2026-11-10); negcts.mp4,
8added later the same day, likewise (two runs, sha256 0bfdca41...47b6e2 both times).
9
10Why -aac_pns 0: ffmpeg's AAC encoder uses perceptual noise substitution by default, and the decoder fills
11those bands from a pseudo-random generator whose state runs through the whole stream. A file decoded
12from a later packet then differs by about 1 LSB in scattered samples for the rest of the stream, whatever
13the container does. MEASURED 2026-11-10 on the av_fast.mp4 command with and without the option, trimmed
141.2..2.6 s by ovideo, decoded to s16le: with PNS 6358 of 123536 bytes differ from the same source range,
15without PNS 0 differ. So decoded-audio hashes are an oracle only for PNS-free audio; pns.mp4 keeps the
16default to show the class: its packets are compared byte for byte, its decoded audio is not.
17
18av_end.mp4 H.264 + AAC, moov at the end, no B-frames (no ctts), GOP 25, video 12800 / audio 48000:
19 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=4 -f lavfi -i sine=frequency=440:sample_rate=48000:duration=4 $X -g 25 -bf 0 $A -b:a 64k $O corpus/av_end.mp4
20av_fast.mp4 moov at the front (faststart), B-frames (ctts, edit lists), GOP 30, audio 44100:
21 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=4 -f lavfi -i sine=frequency=660:sample_rate=44100:duration=4 $X -g 30 -bf 2 $A -b:a 64k -movflags +faststart $O corpus/av_fast.mp4
22pns.mp4 as av_fast.mp4 but with the encoder's default perceptual noise substitution (see above):
23 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=4 -f lavfi -i sine=frequency=660:sample_rate=44100:duration=4 $X -g 30 -bf 2 -c:a aac -b:a 64k -movflags +faststart $O corpus/pns.mp4
24negcts.mp4 as av_fast.mp4 but with negative composition offsets: video ctts version 1 (signed offsets,
25 MEASURED -512..1024 in 71 entries) and a video edit at media time 0 instead of one that shifts
26 presentation, so trim, join and whole-range trim exercise the version-1 ctts writer:
27 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=4 -f lavfi -i sine=frequency=660:sample_rate=44100:duration=4 $X -g 30 -bf 2 $A -b:a 64k -movflags +faststart+negative_cts_offsets $O corpus/negcts.mp4
28vonly.mov QuickTime, video only, B-frames, movie track timescale 600, 30 frames/s:
29 ffmpeg $F -f lavfi -i testsrc2=size=320x240:rate=30:duration=3 $X -g 15 -bf 3 -video_track_timescale 600 -f mov $O corpus/vonly.mov
30aonly.m4a audio only, AAC 44100:
31 ffmpeg $F -f lavfi -i sine=frequency=330:sample_rate=44100:duration=5 $A -b:a 96k $O corpus/aonly.m4a
32intra.mp4 all-intra video (every sample a sync sample), video timescale 90000, 24 frames/s, mono 22050 audio:
33 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=24:duration=2 -f lavfi -i sine=frequency=550:sample_rate=22050:duration=2 $X -g 1 -bf 0 -video_track_timescale 90000 $A -b:a 48k $O corpus/intra.mp4
34longgop.mp4 long GOP (250 frames, one sync sample per 10 s), B-frames, 12 s:
35 ffmpeg $F -f lavfi -i testsrc=size=160x120:rate=25:duration=12 -f lavfi -i sine=frequency=440:sample_rate=48000:duration=12 $X -g 250 -keyint_min 250 -sc_threshold 0 -bf 3 $A -b:a 32k $O corpus/longgop.mp4
36elst.mp4 audio starts 0.5 s after video: the audio track's edit list begins with an empty edit:
37 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=4 -itsoffset 0.5 -f lavfi -i sine=frequency=440:sample_rate=48000:duration=3 $X -g 25 -bf 0 $A -b:a 64k $O corpus/elst.mp4
38frag.mp4 fragmented (moof), refused with code 30:
39 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=2 $X -g 25 -bf 0 -movflags frag_keyframe+empty_moov $O corpus/frag.mp4
40tmcd.mov QuickTime with a timecode (tmcd) track, refused by trim and join with code 32:
41 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=2 -f lavfi -i sine=frequency=440:sample_rate=48000:duration=2 $X -g 25 -bf 0 $A -b:a 64k -timecode 01:00:00:00 -f mov $O corpus/tmcd.mov
42text.mp4 a 3GPP timed text (mov_text) track from corpus/src/cues.srt, refused by trim and join with code 32:
43 ffmpeg $F -f lavfi -i testsrc=size=320x240:rate=25:duration=4 -i corpus/src/cues.srt $X -g 25 -bf 0 -c:s mov_text $O corpus/text.mp4
44
45Generated by the gate into build/gate/ (never committed), from tests/mkcases.om compiled with the pinned omc:
46co64.mp4 build/mkcases corpus/av_end.mp4 build/gate/co64.mp4 0 every stco rewritten as co64
47sparse4g.mp4 build/mkcases corpus/av_end.mp4 build/gate/sparse4g.mp4 1 4295049056 bytes, a sparse file
48 (84 KiB allocated on ext4): ftyp, a free box with largesize 2^32 whose body is a hole, then the
49 rest; first video sample at offset 0x10000012c, co64
50v1large.mp4 build/mkcases corpus/av_end.mp4 build/gate/v1large.mp4 2 co64, version 1 mvhd/tkhd/mdhd/elst,
51 largesize headers on moov, trak, mdia, minf, stbl and edts
52ffmpeg decodes all three to the same framemd5 as av_end.mp4 (2026-11-10, before the -aac_pns 0 regeneration;
53the gate rechecks on every run).