FilmCraft: An open-source, nonlinear video editor written by scratch in pure Rust
Merge branch 'main' into worktree-agent-a861ca53f77717930
Brandon Thomas81873deedb88
diff --cc Cargo.tomlindex 35354677c,02dfdf88b..a513474df--- a/Cargo.toml+++ b/Cargo.toml@@@ -19,7 -19,9 +19,10 @@@ filmcraft-bitstream = { path = "crates/filmcraft-isobmff = { path = "crates/isobmff" }filmcraft-matroska = { path = "crates/matroska" }filmcraft-mxf = { path = "crates/mxf" }+filmcraft-cfb = { path = "crates/cfb" }+ filmcraft-mpegts = { path = "crates/mpegts" }+ filmcraft-mpeg2v = { path = "crates/mpeg2v" }+ filmcraft-ac3 = { path = "crates/ac3" }filmcraft-ogg = { path = "crates/ogg" }filmcraft-h264 = { path = "crates/h264" }filmcraft-hevc = { path = "crates/hevc" }diff --cc crates/mxf/README.mdindex 13ed3c2dd,7d833b318..043772477--- a/crates/mxf/README.md+++ b/crates/mxf/README.md@@@ -131,16 -79,6 +131,16 @@@ w.finish()?600 random mutations never panic and only list fully-present samples.- `crates/codecs/tests/mxf_oracle.rs` (FFmpeg-written fixtures, FFmpeg as the decode oracle):H.264 long-GOP with B pictures (bit-exact every frame + 25 random seeks), H.264 29.97 DF- timecode, DNxHR LB (±2), ProRes 422 (±1), MPEG-2 (reported unsupported, audio exact),+ timecode, DNxHR LB (±2), ProRes 422 (±1), MPEG-2 long GOP, XDCAM HD422 and D-10 (±4),OP-Atom VC-3 (clip-wrapped) and PCM, D-10 AES3 audio; PCM sample-exact in every file;truncated and corrupted files. `cargo xtask fixtures codecs` pre-generates them.+- `src/write/tests.rs`: writer output read back by `open`: OP1a with two sound tracks pushed in+ uneven chunks (durations, codec label, aspect, PCM exact, index slices, closed partitions),+ 29.97 sound per edit unit (1601/1602), a long-GOP AVC index (presentation order, key and B+ flags), OP-Atom picture (clip wrapping) and PCM files at both edit rates, multi-segment index+ of 12 000 units, UMIDs; truncation and random mutation of written files never panic.+- `crates/export/src/mxf_tests.rs` (ffprobe / ffmpeg as external oracles): OP1a exports with+ DNxHR, ProRes and H.264 — ffprobe reports the OP1a label, codec, 24 frames, frame rate, duration+ and `01:00:00:00` timecode; ffmpeg decodes the MXF picture exactly as it decodes the same+ essence exported as MOV, and its PCM equals our demuxer's sample for sample; OP-Atom exports —+ picture file and one mono file per channel, each channel equal to the WAV export's.diff --cc docs/architecture.mdindex 2b36209f0,82e7e3ef6..08818dec1--- a/docs/architecture.md+++ b/docs/architecture.md@@@ -27,7 -27,7 +27,7 @@@ Design principlesL2 edit · codecs · interchange · captions · speechL1 frame · media · project · audio-dsp · textL0 foundation: time · geom · color · bitstream · testkit (dev-dependency only)- codecs/containers: isobmff · matroska · mxf · cfb · ogg · h264 · h264enc · hevc · vp9 · av1 · prores · dnx · aac · opus- codecs/containers: isobmff · matroska · mxf · mpegts · ogg · h264 · h264enc · hevc · vp9 · av1 · mpeg2v · prores · dnx · aac · ac3 · opus++ codecs/containers: isobmff · matroska · mxf · cfb · mpegts · ogg · h264 · h264enc · hevc · vp9 · av1 · mpeg2v · prores · dnx · aac · ac3 · opus```Crates are named `filmcraft-<dir>` (`crates/time` is `filmcraft-time`). The apps are `filmcraft`@@@ -41,8 -41,8 +41,9 @@@ and `filmcraft-cli`| `bitstream` | L0 | bit reader/writer, Exp-Golomb, emulation prevention || `isobmff` | L0 | MP4/MOV demux and mux || `matroska` | L0 | MKV/WebM demux |-| `mxf` | L0 | MXF demux (SMPTE ST 377-1): OP1a / OP-Atom, index tables, AVC / VC-3 / ProRes / MPEG-2 identification, PCM / AES3 sound, timecode ([README](../crates/mxf/README.md)) |+| `mxf` | L0 | MXF demux and mux (SMPTE ST 377-1): OP1a / OP-Atom, index tables, AVC / VC-3 / ProRes / MPEG-2 identification, PCM / AES3 sound, timecode; writer for OP1a / OP-Atom with VC-3, ProRes, AVC and PCM ([README](../crates/mxf/README.md)) |+| `cfb` | L0 | Compound File Binary ([MS-CFB] structured storage) reader and writer, the container of AAF ([README](../crates/cfb/README.md)) |+ | `mpegts` | L0 | MPEG-2 Systems demux (H.222.0): transport streams (188 / 192-byte BDAV / 204), program streams (MPEG-2 / MPEG-1, VOB, MOD), PSI, PES, PTS / PCR, access-unit index built on open ([README](../crates/mpegts/README.md)) || `ogg` | L0 | Ogg demux (RFC 3533), Ogg Opus timing (RFC 7845 granules, pre-skip, end trimming), Vorbis headers || `h264`, `h264enc` | L0 | H.264 decoder; H.264 encoder || `hevc` | L0 | H.265 Main/Main 10 decoder |@@@ -58,8 -60,8 +61,8 @@@| `text` | L1 | text engine: font database (bundled OFL fonts + system fonts), shaping (harfrust), bidi, line breaking, paragraph layout, glyph/path rasteriser, strokes ([crates/text/README.md](../crates/text/README.md)) || `edit` | L2 | pure edit algebra (insert, overwrite, razor, ripple, roll, slip, slide, rate stretch…; text-based editing: `edit::transcript`) || `speech` | L2 | speech-to-text: `Transcriber` trait, Whisper model catalogue + verified downloader (feature `download`), pure-Rust Whisper inference on candle with word timestamps (feature `whisper`), speaker labelling ([transcripts.md](transcripts.md)) |- | `codecs` | L2 | container + codec hub: MP4/MOV, MKV, MXF and Ogg sources, GOP-aware seeking, decoder registry, audio decoding |+ | `codecs` | L2 | container + codec hub: MP4/MOV, MKV, MXF, Ogg and MPEG TS / PS / video elementary stream sources, GOP-aware seeking, decoder registry, audio decoding |-| `interchange` | L2 | EDL, FCP7 XML, FCPXML and OTIO import/export (no file I/O) |+| `interchange` | L2 | EDL, FCP7 XML, FCPXML, OTIO, AAF (on `cfb`) and OMF 2.0 import/export (no file I/O; the engine supplies rendered audio essence) ([README](../crates/interchange/README.md)) || `render` | L3 | sequence evaluation, CPU compositor, video effects (`effects`, `vfx`; effects needing other frames or tracks read them through `vfx::FxEnv`), transitions, audio mix || `gpu` | L3 | wgpu compositor (WGSL) || `golden` | L3 | test-only: golden-image tests of the CPU renderer and GPU-vs-CPU parity; empty library, dev-dependencies only |diff --cc xtask/src/main.rsindex 48e2172a3,fedffaac1..6625e2313--- a/xtask/src/main.rs+++ b/xtask/src/main.rs@@@ -31,7 -31,9 +31,10 @@@ const LAYERS: &[(&str, u8)] = &("isobmff", 0),("matroska", 0),("mxf", 0),+ ("cfb", 0),+ ("mpegts", 0),+ ("mpeg2v", 0),+ ("ac3", 0),("ogg", 0),("riff", 0),("h264", 0),