From 141d212310137e8380301ec6ce01125deaf2b595 Mon Sep 17 00:00:00 2001 From: t0ms Date: Thu, 1 Oct 2026 11:42:33 +0100 Subject: [PATCH 01/11] quest(m1): plan TS passthrough and release clock recovery Co-authored-by: Cursor --- quest/m1/README.md | 2 + quest/m1/release-clock-recovery.md | 60 +++++++++++++++++++++ quest/m1/ts-passthrough.md | 84 ++++++++++++++++++++++++++++++ quest/m1/tstd/README.md | 5 ++ quest/m2/msfts-convergence.md | 14 +++-- 5 files changed, 160 insertions(+), 5 deletions(-) create mode 100644 quest/m1/release-clock-recovery.md create mode 100644 quest/m1/ts-passthrough.md diff --git a/quest/m1/README.md b/quest/m1/README.md index da1236cff08..1b56bbd93ed 100644 --- a/quest/m1/README.md +++ b/quest/m1/README.md @@ -159,6 +159,8 @@ QUIC studies there on that rule. - [Audio warmup](/quest/m1/audio-warmup.md) - a viewer joining an Opus rendition mid-stream never hears the unconverged first 80 ms - [#3021](/quest/m1/3021-moq-gst-anchor-generated-media-timelines-to-wall-clock.md) - moq-gst picks the broadcast wall epoch; a restarted source is a new epoch, not a forward re-anchor - [T-STD TS export](/quest/m1/tstd/README.md) - `moq export ts` is a proper remux that passes the T-STD buffer model, starting with a fixed `--delay` +- [Release clock recovery](/quest/m1/release-clock-recovery.md) - the fixed-delay release holds its delay against a publisher clock off by up to ±30 ppm, steering within 13818-1's limits +- [TS passthrough](/quest/m1/ts-passthrough.md) - `--passthrough` carries the multiplex as MSFTS whole packets and writes it back byte-identical on a fixed delay - [FLV export delay](/quest/m1/flv-export-delay.md) - FLV interleaves through the shared fixed-delay release stage - [MKV export delay](/quest/m1/mkv-export-delay.md) - MKV interleaves through the shared fixed-delay release stage - [Release profile](/quest/m1/release-profile.md) - every release build gets fat LTO, one codegen unit, and stripping from the workspace profile instead of three script exports diff --git a/quest/m1/release-clock-recovery.md b/quest/m1/release-clock-recovery.md new file mode 100644 index 00000000000..f3ddb50dac2 --- /dev/null +++ b/quest/m1/release-clock-recovery.md @@ -0,0 +1,60 @@ +# [M] Fixed-delay release holds its delay against the publisher's clock + +## Goal + +The [fixed-delay release](/quest/m1/tstd/delay.md) stage keeps each frame's +release at its configured delay indefinitely when the publisher's clock runs +off the receiver's by up to the ±30 ppm that ISO 13818-1 allows a system +clock. Today the release is anchored at the first frame's local arrival and +never moves, so the buffer grows or shrinks with the clock difference until +frames start missing their deadlines. The TS export and the TS passthrough +both release through it. + +## Plan + +Decided (2026-10-01), from a discussion with t0ms: + +- Why now, against `delay.md`'s "correct it only if measured": the exposure + is derived, and a mocked-time test shows it without waiting for a soak. At + ±30 ppm the release drifts 108 ms an hour. A receiver whose clock runs + slow lets the buffer grow by that much an hour, so a sink gets later and + later; one whose clock runs fast spends the delay's margin over its + send-ahead, and then every frame misses its deadline and is dropped. With + a 500 ms delay and a few hundred ms of send-ahead, that is a matter of + hours for a 24/7 channel. +- Estimate the offset between media time and local arrival with a floor + filter: the minimum offset over each window, so that queueing and + retransmission delay, which only ever add, do not move the estimate. The + drift is the slope of those floors across windows. Media time is the DTS + for the demultiplexed export and the PCR for passthrough; the stage does + not care which. +- Steer the release clock towards that estimate within 13818-1's own limits + on a system clock: within ±30 ppm of nominal, and changing by no more than + 0.075 Hz/s at 27 MHz. A source outside them is counted and surfaced in the + export's stats, not silently followed. Its margin then erodes, and its late + drops are attributed to drift. +- The PCR values the export writes do not change. Only the wall-clock pace + of the bytes moves, by at most the steering limit, so a receiver + recovering its clock from them sees a clock inside the standard's + tolerance. +- A rewind (a new program generation) re-anchors as it does today, and + restarts the estimate. + +Test with mocked time: a source at +30 ppm and one at -30 ppm over a +simulated 24 h lose no frame to lateness, and hold the release within a +stated bound of the configured delay once converged (proposed: 10 ms). A +source at 50 ppm saturates the steering, and is counted as out of tolerance. +A step in queueing delay does not move the estimate. The slew stays within +0.075 Hz/s throughout. A wall-clock soak against a real drifting source is +the end-to-end gate, run by the [T-STD line](/quest/m1/tstd/README.md). + +Public API: the release stage gains the estimator; its stats gain the drift +estimate and an out-of-tolerance count. Wire: none. + +## Required + +- [Fixed-delay release](/quest/m1/tstd/delay.md) - the stage this steers + +## Related + +- [TS passthrough](/quest/m1/ts-passthrough.md) - releases on the source PCR through the same stage diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md new file mode 100644 index 00000000000..b4dd9cefbf7 --- /dev/null +++ b/quest/m1/ts-passthrough.md @@ -0,0 +1,84 @@ +# [M] TS passthrough carries the multiplex verbatim on a fixed delay + +## Goal + +`moq import ts --passthrough` publishes a transport stream without +demultiplexing it, and `moq export ts --passthrough --delay ` writes the +same bytes back out, paced on the source's own PCR and released at a fixed +delay like an SRT receiver. From the first group it releases, the output is +byte-identical to the input, so it is exactly as T-STD-conformant as the +source. It carries what the demultiplexed lane cannot: TS-level scrambling, +private PIDs, and PSI/SI as authored. There is no JS player for it. + +## Plan + +Decided (2026-10-01), from a discussion with t0ms: + +- Why: the [T-STD line](/quest/m1/tstd/README.md) names a passthrough lane as + the only one that can carry primary distribution until the remux passes, and + none exists. Some feeds will want it permanently: a scrambled multiplex + cannot be demultiplexed, and an operator who must hand on SI and private + PIDs as authored has nothing to gain from a remux. +- Carriage is MSFTS's whole-packet mode, with its own track fields on the + Hang track entry: `packaging: "mpeg2ts"`, `mpeg2tsMode` set to + `"unmodified-program"` for a single program or `"unmodified-multiplex"` + otherwise, `mpeg2tsPacketSize: 188`, `mpeg2tsRandomAccess`, and + `mpeg2tsMuxRate` once measured. The mapping to MSFTS is then the identity, + and the track is the whole-packet shape the draft's comparison section + already describes rather than a new rendition in the `mpegts` section. A + track is one shape or the other. +- Objects are runs of whole 188-byte packets on one track. A group starts at + a packet on the PCR PID that carries a PCR with `random_access_indicator` + set, and also at any PCR with `discontinuity_indicator` set, since MSFTS + forbids a PCR discontinuity inside a group. A source that never sets the + indicator falls back to a group every N PCRs (N to be fixed in the PR, with + a group spanning at most 1 s of PCR time). `mpeg2tsRandomAccess` is true + only while every group has started at an indicator; the first fallback + group republishes the catalog with it false. All of these fields sit in the + adaptation field, which TS scrambling leaves in clear, so a scrambled feed + still groups and paces. Nothing past the adaptation field is parsed. +- Each object's timestamp is the PCR time of its first byte, interpolated + between PCRs at the stream's own rate. Object boundaries and timestamps then + depend only on the bytes, so two publishers of one feed publish identical + objects, which 1+1 needs. +- A multiplex is paced on one PCR PID: the first program's in the PAT, or + `--pcr-pid`. Every byte stays in order behind it. Programs on independent + clocks are out of scope. +- The export reuses the [fixed-delay release](/quest/m1/tstd/delay.md) + stage, keyed on each object's PCR time instead of a DTS, and the CLI's + `Delivery` pacer spreads each object's bytes at the PCR-implied rate. It + must pace on the source's PCR, not on arrival: a pacer that re-clocks on + arrival moves the PCR-to-PTS offset over a long capture and fails the + decoder buffers, even though every byte is intact. +- An object that misses its deadline is dropped and counted, as the release + stage does. The output shows a continuity error there; passthrough never + rewrites continuity counters. +- Source clock drift is handled by + [release clock recovery](/quest/m1/release-clock-recovery.md), shared with + the demultiplexed export, not here. +- No JS player. `js/watch` skips the track as one whose shape it does not + describe. + +Test: an export of a broadcast capture is byte-identical to the input from +the first released group, and the strict T-STD check gives the same verdict +on output and input. A scrambled fixture (`transport_scrambling_control` set +on its elementary PIDs) groups and paces the same as its clear twin. Two +exporters fed the same objects with different arrival skew emit identical +bytes. A dropped object is counted, and the rest still go out on time. Rerun +the #4613 netem rig (10% loss, 120 s) against it. + +Update `doc/bin/cli.md` for both flags, and the draft's comparison section to +say this repository now publishes both shapes. + +Public API: new import and export modes; nothing existing breaks. Wire: the +catalog gains an `mpeg2ts` track entry; additive. + +## Required + +- [Fixed-delay release](/quest/m1/tstd/delay.md) - the release stage this reuses +- [Release clock recovery](/quest/m1/release-clock-recovery.md) - holds the delay against the source clock + +## Related + +- [MSFTS convergence](/quest/m2/msfts-convergence.md) - the ES-level side of the same mapping +- [TS byte schedule](/quest/m1/tstd/byte-schedule.md) - the remux's equivalent of pacing on the source PCR diff --git a/quest/m1/tstd/README.md b/quest/m1/tstd/README.md index ec8f9dc2cff..dde007ffdd2 100644 --- a/quest/m1/tstd/README.md +++ b/quest/m1/tstd/README.md @@ -25,3 +25,8 @@ nightly. - [Fixed-delay release](/quest/m1/tstd/delay.md) - frames go out at media time plus a fixed `--delay`, in one order under loss - [T-STD check](/quest/m1/tstd/check.md) - the harness grades the full buffer model instead of the transport buffer alone - [TS byte schedule](/quest/m1/tstd/byte-schedule.md) - PCRs sit on the byte grid the mux rate implies, paced against the fixed delay + +## Related + +- [TS passthrough](/quest/m1/ts-passthrough.md) - the passthrough lane named in the Goal +- [Release clock recovery](/quest/m1/release-clock-recovery.md) - the fixed delay held against publisher clock drift; the soak gate runs here diff --git a/quest/m2/msfts-convergence.md b/quest/m2/msfts-convergence.md index ac9a67dc4a3..79389b560bc 100644 --- a/quest/m2/msfts-convergence.md +++ b/quest/m2/msfts-convergence.md @@ -4,7 +4,9 @@ A subscriber author can map this repository's demultiplexed TS lane (access units, Hang catalog `mpegts` section) onto MSFTS ES-level carriage -without guessing. Transporting TS verbatim is a non-goal. +without guessing. Transporting TS verbatim is out of scope here: +[TS passthrough](/quest/m1/ts-passthrough.md) carries it with MSFTS's own +track fields. ## Plan @@ -20,7 +22,9 @@ egress moved to msfts#37 (closed). Two differences remain: matter to a subscriber, and converge or document the mapping. Update `drafts/draft-lcurley-moq-mpegts.md` and `doc/concept` with whatever -lands. Open TS PRs [#4577](https://github.com/moq-dev/moq/pull/4577) (per-ES -access units at export), [#4579](https://github.com/moq-dev/moq/pull/4579) -(export on the mux rate), and [#4580](https://github.com/moq-dev/moq/pull/4580) -(per-program SI) touch the same area; land or rebase on them first. +lands. [#4577](https://github.com/moq-dev/moq/pull/4577) (per-ES access +units at export) has merged, and [#4579](https://github.com/moq-dev/moq/pull/4579) +(export on the mux rate) closed in favour of the +[T-STD line](/quest/m1/tstd/README.md). +[#4580](https://github.com/moq-dev/moq/pull/4580) (per-program SI) is still +open and touches the same area; land or rebase on it first. From c2e2f20230f8517167607f076f00160fe1bb66f4 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 15:23:16 -0700 Subject: [PATCH 02/11] quest(m1): list TS passthrough in a hang m2ts catalog section The mpegts section records what demultiplexing loses; every member is in-band under passthrough. A separate m2ts root keyed by track name carries scope, randomAccess, and muxRate instead of MSFTS's flat track fields. Co-Authored-By: Claude Opus 5.5 --- quest/m1/README.md | 2 +- quest/m1/ts-passthrough.md | 45 ++++++++++++++++++++--------------- quest/m2/msfts-convergence.md | 4 ++-- 3 files changed, 29 insertions(+), 22 deletions(-) diff --git a/quest/m1/README.md b/quest/m1/README.md index 2e2b2cbaa67..cd5b56e2f68 100644 --- a/quest/m1/README.md +++ b/quest/m1/README.md @@ -165,7 +165,7 @@ QUIC studies there on that rule. - [#3021](/quest/m1/3021-moq-gst-anchor-generated-media-timelines-to-wall-clock.md) - moq-gst picks the broadcast wall epoch; a restarted source is a new epoch, not a forward re-anchor - [T-STD TS export](/quest/m1/tstd/README.md) - `moq export ts` is a proper remux that passes the T-STD buffer model, starting with a fixed `--delay` - [Release clock recovery](/quest/m1/release-clock-recovery.md) - the fixed-delay release holds its delay against a publisher clock off by up to ±30 ppm, steering within 13818-1's limits -- [TS passthrough](/quest/m1/ts-passthrough.md) - `--passthrough` carries the multiplex as MSFTS whole packets and writes it back byte-identical on a fixed delay +- [TS passthrough](/quest/m1/ts-passthrough.md) - `--passthrough` carries the multiplex as whole packets, listed in an `m2ts` catalog section, and writes it back byte-identical on a fixed delay - [FLV export delay](/quest/m1/flv-export-delay.md) - FLV interleaves through the shared fixed-delay release stage - [MKV export delay](/quest/m1/mkv-export-delay.md) - MKV interleaves through the shared fixed-delay release stage - [Release profile](/quest/m1/release-profile.md) - every release build gets fat LTO, one codegen unit, and stripping from the workspace profile instead of three script exports diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index b4dd9cefbf7..64729ddf718 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -19,28 +19,32 @@ Decided (2026-10-01), from a discussion with t0ms: none exists. Some feeds will want it permanently: a scrambled multiplex cannot be demultiplexed, and an operator who must hand on SI and private PIDs as authored has nothing to gain from a remux. -- Carriage is MSFTS's whole-packet mode, with its own track fields on the - Hang track entry: `packaging: "mpeg2ts"`, `mpeg2tsMode` set to - `"unmodified-program"` for a single program or `"unmodified-multiplex"` - otherwise, `mpeg2tsPacketSize: 188`, `mpeg2tsRandomAccess`, and - `mpeg2tsMuxRate` once measured. The mapping to MSFTS is then the identity, - and the track is the whole-packet shape the draft's comparison section - already describes rather than a new rendition in the `mpegts` section. A - track is one shape or the other. +- The track is listed in a new `m2ts` root section of the hang catalog, + not in `video`/`audio` (it has no codec to describe) and not in the + `mpegts` section, whose members (`tracks`, `program`, `si`, ...) record + what demultiplexing loses and are all in-band here. `m2ts` maps a track + name to `{ scope, randomAccess, muxRate }`: `scope` is `"program"` for a + single program or `"multiplex"` otherwise, and `muxRate` is present only + while the source holds a constant rate, as in `mpegts`. 188-byte packets + only; a 192-byte source is refused, so there is no packet-size field. The + section is specified in `drafts/draft-lcurley-moq-mpegts.md` next to + `mpegts`, with its mapping onto MSFTS's track fields. A track is one shape + or the other. - Objects are runs of whole 188-byte packets on one track. A group starts at a packet on the PCR PID that carries a PCR with `random_access_indicator` set, and also at any PCR with `discontinuity_indicator` set, since MSFTS forbids a PCR discontinuity inside a group. A source that never sets the indicator falls back to a group every N PCRs (N to be fixed in the PR, with - a group spanning at most 1 s of PCR time). `mpeg2tsRandomAccess` is true - only while every group has started at an indicator; the first fallback - group republishes the catalog with it false. All of these fields sit in the + a group spanning at most 1 s of PCR time). `randomAccess` is true only + while every group has started at an indicator; the first fallback group + republishes the catalog with it false. All of these fields sit in the adaptation field, which TS scrambling leaves in clear, so a scrambled feed still groups and paces. Nothing past the adaptation field is parsed. - Each object's timestamp is the PCR time of its first byte, interpolated - between PCRs at the stream's own rate. Object boundaries and timestamps then - depend only on the bytes, so two publishers of one feed publish identical - objects, which 1+1 needs. + between PCRs at the stream's own rate, carried in hang's `legacy` + container (a varint timestamp before the packets) as verbatim tracks are. + Object boundaries and timestamps then depend only on the bytes, so two + publishers of one feed publish identical objects, which 1+1 needs. - A multiplex is paced on one PCR PID: the first program's in the PAT, or `--pcr-pid`. Every byte stays in order behind it. Programs on independent clocks are out of scope. @@ -56,8 +60,10 @@ Decided (2026-10-01), from a discussion with t0ms: - Source clock drift is handled by [release clock recovery](/quest/m1/release-clock-recovery.md), shared with the demultiplexed export, not here. -- No JS player. `js/watch` skips the track as one whose shape it does not - describe. +- Rust only. `js/hang` does not parse `m2ts`, and a player sees no + rendition for the track. +- `--passthrough` publishes only the passthrough track. Publishing it + alongside the demultiplexed tracks is out of scope. Test: an export of a broadcast capture is byte-identical to the input from the first released group, and the strict T-STD check gives the same verdict @@ -67,11 +73,12 @@ exporters fed the same objects with different arrival skew emit identical bytes. A dropped object is counted, and the rest still go out on time. Rerun the #4613 netem rig (10% loss, 120 s) against it. -Update `doc/bin/cli.md` for both flags, and the draft's comparison section to -say this repository now publishes both shapes. +Update `doc/bin/cli.md` for both flags, `doc/concept` for the section, and +the draft's comparison section to say this repository now publishes both +shapes. Public API: new import and export modes; nothing existing breaks. Wire: the -catalog gains an `mpeg2ts` track entry; additive. +hang catalog gains an `m2ts` root section; additive. ## Required diff --git a/quest/m2/msfts-convergence.md b/quest/m2/msfts-convergence.md index 79389b560bc..010289aa5f4 100644 --- a/quest/m2/msfts-convergence.md +++ b/quest/m2/msfts-convergence.md @@ -5,8 +5,8 @@ A subscriber author can map this repository's demultiplexed TS lane (access units, Hang catalog `mpegts` section) onto MSFTS ES-level carriage without guessing. Transporting TS verbatim is out of scope here: -[TS passthrough](/quest/m1/ts-passthrough.md) carries it with MSFTS's own -track fields. +[TS passthrough](/quest/m1/ts-passthrough.md) carries it in an `m2ts` +catalog section that maps onto MSFTS's track fields. ## Plan From 736aed1993c3f2d28c62d1804fe2aee24dea270b Mon Sep 17 00:00:00 2001 From: t0ms Date: Thu, 1 Oct 2026 23:25:41 +0100 Subject: [PATCH 03/11] quest(m1): drop release clock recovery, which #4645 implements --- quest/m1/README.md | 1 - quest/m1/release-clock-recovery.md | 60 ------------------------------ quest/m1/ts-passthrough.md | 8 ++-- quest/m1/tstd/README.md | 1 - 4 files changed, 3 insertions(+), 67 deletions(-) delete mode 100644 quest/m1/release-clock-recovery.md diff --git a/quest/m1/README.md b/quest/m1/README.md index cd5b56e2f68..a1f1eb6ea6a 100644 --- a/quest/m1/README.md +++ b/quest/m1/README.md @@ -164,7 +164,6 @@ QUIC studies there on that rule. - [Audio warmup](/quest/m1/audio-warmup.md) - a viewer joining an Opus rendition mid-stream never hears the unconverged first 80 ms - [#3021](/quest/m1/3021-moq-gst-anchor-generated-media-timelines-to-wall-clock.md) - moq-gst picks the broadcast wall epoch; a restarted source is a new epoch, not a forward re-anchor - [T-STD TS export](/quest/m1/tstd/README.md) - `moq export ts` is a proper remux that passes the T-STD buffer model, starting with a fixed `--delay` -- [Release clock recovery](/quest/m1/release-clock-recovery.md) - the fixed-delay release holds its delay against a publisher clock off by up to ±30 ppm, steering within 13818-1's limits - [TS passthrough](/quest/m1/ts-passthrough.md) - `--passthrough` carries the multiplex as whole packets, listed in an `m2ts` catalog section, and writes it back byte-identical on a fixed delay - [FLV export delay](/quest/m1/flv-export-delay.md) - FLV interleaves through the shared fixed-delay release stage - [MKV export delay](/quest/m1/mkv-export-delay.md) - MKV interleaves through the shared fixed-delay release stage diff --git a/quest/m1/release-clock-recovery.md b/quest/m1/release-clock-recovery.md deleted file mode 100644 index f3ddb50dac2..00000000000 --- a/quest/m1/release-clock-recovery.md +++ /dev/null @@ -1,60 +0,0 @@ -# [M] Fixed-delay release holds its delay against the publisher's clock - -## Goal - -The [fixed-delay release](/quest/m1/tstd/delay.md) stage keeps each frame's -release at its configured delay indefinitely when the publisher's clock runs -off the receiver's by up to the ±30 ppm that ISO 13818-1 allows a system -clock. Today the release is anchored at the first frame's local arrival and -never moves, so the buffer grows or shrinks with the clock difference until -frames start missing their deadlines. The TS export and the TS passthrough -both release through it. - -## Plan - -Decided (2026-10-01), from a discussion with t0ms: - -- Why now, against `delay.md`'s "correct it only if measured": the exposure - is derived, and a mocked-time test shows it without waiting for a soak. At - ±30 ppm the release drifts 108 ms an hour. A receiver whose clock runs - slow lets the buffer grow by that much an hour, so a sink gets later and - later; one whose clock runs fast spends the delay's margin over its - send-ahead, and then every frame misses its deadline and is dropped. With - a 500 ms delay and a few hundred ms of send-ahead, that is a matter of - hours for a 24/7 channel. -- Estimate the offset between media time and local arrival with a floor - filter: the minimum offset over each window, so that queueing and - retransmission delay, which only ever add, do not move the estimate. The - drift is the slope of those floors across windows. Media time is the DTS - for the demultiplexed export and the PCR for passthrough; the stage does - not care which. -- Steer the release clock towards that estimate within 13818-1's own limits - on a system clock: within ±30 ppm of nominal, and changing by no more than - 0.075 Hz/s at 27 MHz. A source outside them is counted and surfaced in the - export's stats, not silently followed. Its margin then erodes, and its late - drops are attributed to drift. -- The PCR values the export writes do not change. Only the wall-clock pace - of the bytes moves, by at most the steering limit, so a receiver - recovering its clock from them sees a clock inside the standard's - tolerance. -- A rewind (a new program generation) re-anchors as it does today, and - restarts the estimate. - -Test with mocked time: a source at +30 ppm and one at -30 ppm over a -simulated 24 h lose no frame to lateness, and hold the release within a -stated bound of the configured delay once converged (proposed: 10 ms). A -source at 50 ppm saturates the steering, and is counted as out of tolerance. -A step in queueing delay does not move the estimate. The slew stays within -0.075 Hz/s throughout. A wall-clock soak against a real drifting source is -the end-to-end gate, run by the [T-STD line](/quest/m1/tstd/README.md). - -Public API: the release stage gains the estimator; its stats gain the drift -estimate and an out-of-tolerance count. Wire: none. - -## Required - -- [Fixed-delay release](/quest/m1/tstd/delay.md) - the stage this steers - -## Related - -- [TS passthrough](/quest/m1/ts-passthrough.md) - releases on the source PCR through the same stage diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index 64729ddf718..ba139d13cb5 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -57,9 +57,8 @@ Decided (2026-10-01), from a discussion with t0ms: - An object that misses its deadline is dropped and counted, as the release stage does. The output shows a continuity error there; passthrough never rewrites continuity counters. -- Source clock drift is handled by - [release clock recovery](/quest/m1/release-clock-recovery.md), shared with - the demultiplexed export, not here. +- Source clock drift is handled by the fixed-delay release's clock recovery + (#4645), shared with the demultiplexed export, not here. - Rust only. `js/hang` does not parse `m2ts`, and a player sees no rendition for the track. - `--passthrough` publishes only the passthrough track. Publishing it @@ -82,8 +81,7 @@ hang catalog gains an `m2ts` root section; additive. ## Required -- [Fixed-delay release](/quest/m1/tstd/delay.md) - the release stage this reuses -- [Release clock recovery](/quest/m1/release-clock-recovery.md) - holds the delay against the source clock +- [Fixed-delay release](/quest/m1/tstd/delay.md) - the release stage this reuses, with its clock recovery (#4645) ## Related diff --git a/quest/m1/tstd/README.md b/quest/m1/tstd/README.md index dde007ffdd2..9e502c0b057 100644 --- a/quest/m1/tstd/README.md +++ b/quest/m1/tstd/README.md @@ -29,4 +29,3 @@ nightly. ## Related - [TS passthrough](/quest/m1/ts-passthrough.md) - the passthrough lane named in the Goal -- [Release clock recovery](/quest/m1/release-clock-recovery.md) - the fixed delay held against publisher clock drift; the soak gate runs here From 4b765467dd08f09b6c2fea327296292e3e45c41b Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 15:30:54 -0700 Subject: [PATCH 04/11] quest(m1): make m2ts one multiplex object with no scope Passthrough always carries the whole multiplex, so a scope field only made mixed program/multiplex tracks representable. Co-Authored-By: Claude Opus 5.5 --- quest/m1/ts-passthrough.md | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index ba139d13cb5..669fd5021ce 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -22,12 +22,13 @@ Decided (2026-10-01), from a discussion with t0ms: - The track is listed in a new `m2ts` root section of the hang catalog, not in `video`/`audio` (it has no codec to describe) and not in the `mpegts` section, whose members (`tracks`, `program`, `si`, ...) record - what demultiplexing loses and are all in-band here. `m2ts` maps a track - name to `{ scope, randomAccess, muxRate }`: `scope` is `"program"` for a - single program or `"multiplex"` otherwise, and `muxRate` is present only - while the source holds a constant rate, as in `mpegts`. 188-byte packets - only; a 192-byte source is refused, so there is no packet-size field. The - section is specified in `drafts/draft-lcurley-moq-mpegts.md` next to + what demultiplexing loses and are all in-band here. `m2ts` is one object, + `{ track, randomAccess, muxRate }`, naming the broadcast's one passthrough + track. Passthrough always carries the whole multiplex: splitting out a + program would rewrite the PAT, so there is no scope field, and a second + multiplex is a second broadcast. `muxRate` is present only while the + source holds a constant rate, as in `mpegts`. 188-byte packets only; a + 192-byte source is refused, so there is no packet-size field. The section is specified in `drafts/draft-lcurley-moq-mpegts.md` next to `mpegts`, with its mapping onto MSFTS's track fields. A track is one shape or the other. - Objects are runs of whole 188-byte packets on one track. A group starts at From afe63d4574649293269d17e33203faca198e5bee Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 15:32:58 -0700 Subject: [PATCH 05/11] quest(m1): pace passthrough in the release stage, not the CLI pacer #4645 deletes the CLI's Delivery pacer; the release stage paces instead. Co-Authored-By: Claude Opus 5.5 --- quest/m1/ts-passthrough.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index 669fd5021ce..d4ae426fd0c 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -50,11 +50,11 @@ Decided (2026-10-01), from a discussion with t0ms: `--pcr-pid`. Every byte stays in order behind it. Programs on independent clocks are out of scope. - The export reuses the [fixed-delay release](/quest/m1/tstd/delay.md) - stage, keyed on each object's PCR time instead of a DTS, and the CLI's - `Delivery` pacer spreads each object's bytes at the PCR-implied rate. It - must pace on the source's PCR, not on arrival: a pacer that re-clocks on - arrival moves the PCR-to-PTS offset over a long capture and fails the - decoder buffers, even though every byte is intact. + stage, keyed on each object's PCR time instead of a DTS, which also + spreads each object's bytes at the PCR-implied rate. It must pace on the + source's PCR, not on arrival: a pacer that re-clocks on arrival moves the + PCR-to-PTS offset over a long capture and fails the decoder buffers, even + though every byte is intact. - An object that misses its deadline is dropped and counted, as the release stage does. The output shows a continuity error there; passthrough never rewrites continuity counters. From 334578c27c417662a056776fa963947d738379c0 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 15:37:11 -0700 Subject: [PATCH 06/11] quest(m1): make TS passthrough the 1+1 lane Co-Authored-By: Claude Opus 5.5 --- quest/m1/ts-passthrough.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index d4ae426fd0c..a23d989b258 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -60,6 +60,12 @@ Decided (2026-10-01), from a discussion with t0ms: rewrites continuity counters. - Source clock drift is handled by the fixed-delay release's clock recovery (#4645), shared with the demultiplexed export, not here. +- Passthrough is the ST 2022-7 (1+1) lane: two exporters fed the same + objects emit identical bytes, continuity counters included. The + demultiplexed export does not promise counter identity; matching them + there would need a dedicated PCR PID on every export. Aligning the legs in + time is a non-goal: each releases at its own first arrival plus the delay, + so their skew is the path difference, which a 2022-7 receiver absorbs. - Rust only. `js/hang` does not parse `m2ts`, and a player sees no rendition for the track. - `--passthrough` publishes only the passthrough track. Publishing it From bfad51d101416faf803b692678b90f427a061822 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 15:43:26 -0700 Subject: [PATCH 07/11] quest(m1): scope passthrough random access to one program, allow PSI reads randomAccess from one PCR PID's RAI says nothing about other programs' GOPs, and the PCR PID lives in the PMT, so the publisher must read PAT/PMT. Co-Authored-By: Claude Opus 5.5 --- quest/m1/ts-passthrough.md | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index a23d989b258..4f7430939b6 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -37,17 +37,23 @@ Decided (2026-10-01), from a discussion with t0ms: forbids a PCR discontinuity inside a group. A source that never sets the indicator falls back to a group every N PCRs (N to be fixed in the PR, with a group spanning at most 1 s of PCR time). `randomAccess` is true only - while every group has started at an indicator; the first fallback group - republishes the catalog with it false. All of these fields sit in the - adaptation field, which TS scrambling leaves in clear, so a scrambled feed - still groups and paces. Nothing past the adaptation field is parsed. + while the PAT lists a single program and every group has started at an + indicator; the first fallback group republishes the catalog with it false. + A multi-program multiplex always publishes false, since programs sharing a + clock can stagger their GOPs, so one PID's indicator says nothing about + the others. All of these fields sit in the adaptation field, which TS + scrambling leaves in clear, so a scrambled feed still groups and paces. +- The publisher reads the PAT and PMT (with the existing `ts/psi.rs` + parsers) to find the PCR PID and count programs, and parses nothing else + past the adaptation field. PSI is never scrambled, and every byte is still + published as received. - Each object's timestamp is the PCR time of its first byte, interpolated between PCRs at the stream's own rate, carried in hang's `legacy` container (a varint timestamp before the packets) as verbatim tracks are. Object boundaries and timestamps then depend only on the bytes, so two publishers of one feed publish identical objects, which 1+1 needs. -- A multiplex is paced on one PCR PID: the first program's in the PAT, or - `--pcr-pid`. Every byte stays in order behind it. Programs on independent +- A multiplex is paced on one PCR PID: the `PCR_PID` in the PMT of the PAT's + first program, or `--pcr-pid`. Every byte stays in order behind it. Programs on independent clocks are out of scope. - The export reuses the [fixed-delay release](/quest/m1/tstd/delay.md) stage, keyed on each object's PCR time instead of a DTS, which also @@ -74,7 +80,10 @@ Decided (2026-10-01), from a discussion with t0ms: Test: an export of a broadcast capture is byte-identical to the input from the first released group, and the strict T-STD check gives the same verdict on output and input. A scrambled fixture (`transport_scrambling_control` set -on its elementary PIDs) groups and paces the same as its clear twin. Two +on its elementary PIDs) groups and paces the same as its clear twin. A +two-program fixture on one clock with staggered GOPs publishes +`randomAccess` false. PCR discovery finds a PCR PID that differs from the +PMT PID, with the PMT section split across packets. Two exporters fed the same objects with different arrival skew emit identical bytes. A dropped object is counted, and the rest still go out on time. Rerun the #4613 netem rig (10% loss, 120 s) against it. From 4fd316cc406659e414b178789a1f3e1236d81c5a Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 15:53:52 -0700 Subject: [PATCH 08/11] quest(m1): group passthrough at video random access points An RAI on a PCR PID that carries audio can start a group mid-GOP. Also scope 1+1 identity to objects both legs release, and only count random-access groups toward randomAccess. Co-Authored-By: Claude Opus 5.5 --- quest/m1/README.md | 2 +- quest/m1/ts-passthrough.md | 53 ++++++++++++++++++++++---------------- 2 files changed, 32 insertions(+), 23 deletions(-) diff --git a/quest/m1/README.md b/quest/m1/README.md index a1f1eb6ea6a..21c3930e2f7 100644 --- a/quest/m1/README.md +++ b/quest/m1/README.md @@ -164,7 +164,7 @@ QUIC studies there on that rule. - [Audio warmup](/quest/m1/audio-warmup.md) - a viewer joining an Opus rendition mid-stream never hears the unconverged first 80 ms - [#3021](/quest/m1/3021-moq-gst-anchor-generated-media-timelines-to-wall-clock.md) - moq-gst picks the broadcast wall epoch; a restarted source is a new epoch, not a forward re-anchor - [T-STD TS export](/quest/m1/tstd/README.md) - `moq export ts` is a proper remux that passes the T-STD buffer model, starting with a fixed `--delay` -- [TS passthrough](/quest/m1/ts-passthrough.md) - `--passthrough` carries the multiplex as whole packets, listed in an `m2ts` catalog section, and writes it back byte-identical on a fixed delay +- [TS passthrough](/quest/m1/ts-passthrough.md) - `--passthrough` carries the multiplex as whole packets, listed in an `m2ts` catalog section, and writes it back byte-identical (less late drops) on a fixed delay - [FLV export delay](/quest/m1/flv-export-delay.md) - FLV interleaves through the shared fixed-delay release stage - [MKV export delay](/quest/m1/mkv-export-delay.md) - MKV interleaves through the shared fixed-delay release stage - [Release profile](/quest/m1/release-profile.md) - every release build gets fat LTO, one codegen unit, and stripping from the workspace profile instead of three script exports diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index 4f7430939b6..f24959e2a9b 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -16,8 +16,8 @@ Decided (2026-10-01), from a discussion with t0ms: - Why: the [T-STD line](/quest/m1/tstd/README.md) names a passthrough lane as the only one that can carry primary distribution until the remux passes, and - none exists. Some feeds will want it permanently: a scrambled multiplex - cannot be demultiplexed, and an operator who must hand on SI and private + none exists. Some feeds will want it permanently: the demultiplexed lane + cannot parse a scrambled elementary stream into frames, and an operator who must hand on SI and private PIDs as authored has nothing to gain from a remux. - The track is listed in a new `m2ts` root section of the hang catalog, not in `video`/`audio` (it has no codec to describe) and not in the @@ -28,25 +28,30 @@ Decided (2026-10-01), from a discussion with t0ms: program would rewrite the PAT, so there is no scope field, and a second multiplex is a second broadcast. `muxRate` is present only while the source holds a constant rate, as in `mpegts`. 188-byte packets only; a - 192-byte source is refused, so there is no packet-size field. The section is specified in `drafts/draft-lcurley-moq-mpegts.md` next to + 192-byte source is refused, so there is no packet-size field. This quest + specifies the section in `drafts/draft-lcurley-moq-mpegts.md` next to `mpegts`, with its mapping onto MSFTS's track fields. A track is one shape or the other. - Objects are runs of whole 188-byte packets on one track. A group starts at - a packet on the PCR PID that carries a PCR with `random_access_indicator` - set, and also at any PCR with `discontinuity_indicator` set, since MSFTS - forbids a PCR discontinuity inside a group. A source that never sets the - indicator falls back to a group every N PCRs (N to be fixed in the PR, with - a group spanning at most 1 s of PCR time). `randomAccess` is true only - while the PAT lists a single program and every group has started at an - indicator; the first fallback group republishes the catalog with it false. - A multi-program multiplex always publishes false, since programs sharing a - clock can stagger their GOPs, so one PID's indicator says nothing about - the others. All of these fields sit in the adaptation field, which TS - scrambling leaves in clear, so a scrambled feed still groups and paces. + a packet with `random_access_indicator` set on the program's video PID + (its `stream_type` read from the PMT), or on the PCR PID when the program + has no video, so a joiner lands on a decodable picture whichever PID + carries the PCR. A group also starts at any PCR with + `discontinuity_indicator` set, since MSFTS forbids a PCR discontinuity + inside a group. A source that never sets the random-access indicator + falls back to a group every N PCRs (N to be fixed in the PR, with a group + spanning at most 1 s of PCR time). Pacing stays on the PCR PID throughout. +- `randomAccess` is true only while the PAT lists a single program and every + group has started at a `random_access_indicator`. The first group that + starts without one (a fallback, or a `discontinuity_indicator` alone) + republishes the catalog with it false. A multi-program multiplex always + publishes false, since programs sharing a clock can stagger their GOPs. + Both indicators sit in the adaptation field, which TS scrambling leaves in + clear, so a scrambled feed still groups and paces. - The publisher reads the PAT and PMT (with the existing `ts/psi.rs` - parsers) to find the PCR PID and count programs, and parses nothing else - past the adaptation field. PSI is never scrambled, and every byte is still - published as received. + parsers) to find the PCR and video PIDs and count programs, and parses + nothing else past the adaptation field. PSI is never scrambled, and every + byte is still published as received. - Each object's timestamp is the PCR time of its first byte, interpolated between PCRs at the stream's own rate, carried in hang's `legacy` container (a varint timestamp before the packets) as verbatim tracks are. @@ -67,7 +72,9 @@ Decided (2026-10-01), from a discussion with t0ms: - Source clock drift is handled by the fixed-delay release's clock recovery (#4645), shared with the demultiplexed export, not here. - Passthrough is the ST 2022-7 (1+1) lane: two exporters fed the same - objects emit identical bytes, continuity counters included. The + objects emit identical bytes for every object both release, continuity + counters included. An object one leg drops late is a gap in that leg + only, which the 2022-7 receiver fills from the other. The demultiplexed export does not promise counter identity; matching them there would need a dedicated PCR PID on every export. Aligning the legs in time is a non-goal: each releases at its own first arrival plus the delay, @@ -82,10 +89,12 @@ the first released group, and the strict T-STD check gives the same verdict on output and input. A scrambled fixture (`transport_scrambling_control` set on its elementary PIDs) groups and paces the same as its clear twin. A two-program fixture on one clock with staggered GOPs publishes -`randomAccess` false. PCR discovery finds a PCR PID that differs from the -PMT PID, with the PMT section split across packets. Two -exporters fed the same objects with different arrival skew emit identical -bytes. A dropped object is counted, and the rest still go out on time. Rerun +`randomAccess` false. A single-program fixture with the PCR on its audio PID +starts groups at video random access points only. PCR discovery finds a PCR +PID that differs from the PMT PID, with the PMT section split across +packets. Two exporters fed the same objects with different arrival skew emit +identical bytes; when only one misses a deadline, its output is the other's +less that object's packets. A dropped object is counted, and the rest still go out on time. Rerun the #4613 netem rig (10% loss, 120 s) against it. Update `doc/bin/cli.md` for both flags, `doc/concept` for the section, and From 6a97d957bf5978cdd9e1ad2e128ad8ab495c95ea Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 15:54:12 -0700 Subject: [PATCH 09/11] quest(m1): rewrap ts-passthrough Co-Authored-By: Claude Opus 5.5 --- quest/m1/ts-passthrough.md | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index f24959e2a9b..0894df080be 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -17,8 +17,9 @@ Decided (2026-10-01), from a discussion with t0ms: - Why: the [T-STD line](/quest/m1/tstd/README.md) names a passthrough lane as the only one that can carry primary distribution until the remux passes, and none exists. Some feeds will want it permanently: the demultiplexed lane - cannot parse a scrambled elementary stream into frames, and an operator who must hand on SI and private - PIDs as authored has nothing to gain from a remux. + cannot parse a scrambled elementary stream into frames, and an operator + who must hand on SI and private PIDs as authored has nothing to gain from + a remux. - The track is listed in a new `m2ts` root section of the hang catalog, not in `video`/`audio` (it has no codec to describe) and not in the `mpegts` section, whose members (`tracks`, `program`, `si`, ...) record @@ -58,8 +59,8 @@ Decided (2026-10-01), from a discussion with t0ms: Object boundaries and timestamps then depend only on the bytes, so two publishers of one feed publish identical objects, which 1+1 needs. - A multiplex is paced on one PCR PID: the `PCR_PID` in the PMT of the PAT's - first program, or `--pcr-pid`. Every byte stays in order behind it. Programs on independent - clocks are out of scope. + first program, or `--pcr-pid`. Every byte stays in order behind it. Programs + on independent clocks are out of scope. - The export reuses the [fixed-delay release](/quest/m1/tstd/delay.md) stage, keyed on each object's PCR time instead of a DTS, which also spreads each object's bytes at the PCR-implied rate. It must pace on the @@ -84,18 +85,18 @@ Decided (2026-10-01), from a discussion with t0ms: - `--passthrough` publishes only the passthrough track. Publishing it alongside the demultiplexed tracks is out of scope. -Test: an export of a broadcast capture is byte-identical to the input from -the first released group, and the strict T-STD check gives the same verdict -on output and input. A scrambled fixture (`transport_scrambling_control` set -on its elementary PIDs) groups and paces the same as its clear twin. A -two-program fixture on one clock with staggered GOPs publishes -`randomAccess` false. A single-program fixture with the PCR on its audio PID -starts groups at video random access points only. PCR discovery finds a PCR -PID that differs from the PMT PID, with the PMT section split across -packets. Two exporters fed the same objects with different arrival skew emit -identical bytes; when only one misses a deadline, its output is the other's -less that object's packets. A dropped object is counted, and the rest still go out on time. Rerun -the #4613 netem rig (10% loss, 120 s) against it. +Test: an export of a broadcast capture is byte-identical to the input from the +first released group, and the strict T-STD check gives the same verdict on +output and input. A scrambled fixture (`transport_scrambling_control` set on +its elementary PIDs) groups and paces the same as its clear twin. A +two-program fixture on one clock with staggered GOPs publishes `randomAccess` +false. A single-program fixture with the PCR on its audio PID starts groups at +video random access points only. PCR discovery finds a PCR PID that differs +from the PMT PID, with the PMT section split across packets. Two exporters fed +the same objects with different arrival skew emit identical bytes; when only +one misses a deadline, its output is the other's less that object's packets. A +dropped object is counted, and the rest still go out on time. Rerun the #4613 +netem rig (10% loss, 120 s) against it. Update `doc/bin/cli.md` for both flags, `doc/concept` for the section, and the draft's comparison section to say this repository now publishes both From 4a1a33f7a386f0300723bdf755d0d901a2c68b84 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 16:00:06 -0700 Subject: [PATCH 10/11] quest(m1): limit passthrough random access to one video PID, scope 1+1 to TS identity Co-Authored-By: Claude Opus 5.5 --- quest/m1/ts-passthrough.md | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index 0894df080be..dab9c59db3b 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -42,11 +42,12 @@ Decided (2026-10-01), from a discussion with t0ms: inside a group. A source that never sets the random-access indicator falls back to a group every N PCRs (N to be fixed in the PR, with a group spanning at most 1 s of PCR time). Pacing stays on the PCR PID throughout. -- `randomAccess` is true only while the PAT lists a single program and every - group has started at a `random_access_indicator`. The first group that - starts without one (a fallback, or a `discontinuity_indicator` alone) - republishes the catalog with it false. A multi-program multiplex always - publishes false, since programs sharing a clock can stagger their GOPs. +- `randomAccess` is true only while the PAT lists a single program with at + most one video PID, and every group has started at a + `random_access_indicator`. The first group that starts without one (a + fallback, or a `discontinuity_indicator` alone) republishes the catalog + with it false. Any other layout always publishes false, since programs or + video streams sharing a clock can stagger their GOPs. Both indicators sit in the adaptation field, which TS scrambling leaves in clear, so a scrambled feed still groups and paces. - The publisher reads the PAT and PMT (with the existing `ts/psi.rs` @@ -72,10 +73,11 @@ Decided (2026-10-01), from a discussion with t0ms: rewrites continuity counters. - Source clock drift is handled by the fixed-delay release's clock recovery (#4645), shared with the demultiplexed export, not here. -- Passthrough is the ST 2022-7 (1+1) lane: two exporters fed the same - objects emit identical bytes for every object both release, continuity - counters included. An object one leg drops late is a gap in that leg - only, which the 2022-7 receiver fills from the other. The +- Passthrough is the 1+1 lane: two exporters fed the same objects emit + identical TS packets for every object both release, continuity counters + included; an object one leg drops late is a gap in that leg only. That is + TS identity, not ST 2022-7 recovery, which also needs matching RTP + headers: a coordinated RTP egress would be its own quest. The demultiplexed export does not promise counter identity; matching them there would need a dedicated PCR PID on every export. Aligning the legs in time is a non-goal: each releases at its own first arrival plus the delay, @@ -90,13 +92,14 @@ first released group, and the strict T-STD check gives the same verdict on output and input. A scrambled fixture (`transport_scrambling_control` set on its elementary PIDs) groups and paces the same as its clear twin. A two-program fixture on one clock with staggered GOPs publishes `randomAccess` -false. A single-program fixture with the PCR on its audio PID starts groups at -video random access points only. PCR discovery finds a PCR PID that differs -from the PMT PID, with the PMT section split across packets. Two exporters fed -the same objects with different arrival skew emit identical bytes; when only -one misses a deadline, its output is the other's less that object's packets. A -dropped object is counted, and the rest still go out on time. Rerun the #4613 -netem rig (10% loss, 120 s) against it. +false, as does one program with two staggered video PIDs. A single-program +fixture with the PCR on its audio PID starts groups at video random access +points only. PCR discovery finds a PCR PID that differs from the PMT PID, with +the PMT section split across packets. Two exporters fed the same objects with +different arrival skew emit identical bytes; when only one misses a deadline, +its output is the other's less that object's packets. A dropped object is +counted, and the rest still go out on time. Rerun the #4613 netem rig (10% +loss, 120 s) against it. Update `doc/bin/cli.md` for both flags, `doc/concept` for the section, and the draft's comparison section to say this repository now publishes both From 79a95ce47e0c7bd9d375592b63eeace9d7ea42d3 Mon Sep 17 00:00:00 2001 From: Luke Curley Date: Thu, 1 Oct 2026 16:06:50 -0700 Subject: [PATCH 11/11] quest(m1): defer passthrough leg alignment to ts-hitless's --sync #4680 plans demuxed-lane 2022-7 identity with a shared catalog-clock anchor; passthrough keeps its free TS identity and adopts that anchor. Co-Authored-By: Claude Opus 5.5 --- quest/m1/ts-passthrough.md | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/quest/m1/ts-passthrough.md b/quest/m1/ts-passthrough.md index dab9c59db3b..03fb1c0057e 100644 --- a/quest/m1/ts-passthrough.md +++ b/quest/m1/ts-passthrough.md @@ -73,15 +73,14 @@ Decided (2026-10-01), from a discussion with t0ms: rewrites continuity counters. - Source clock drift is handled by the fixed-delay release's clock recovery (#4645), shared with the demultiplexed export, not here. -- Passthrough is the 1+1 lane: two exporters fed the same objects emit - identical TS packets for every object both release, continuity counters - included; an object one leg drops late is a gap in that leg only. That is - TS identity, not ST 2022-7 recovery, which also needs matching RTP - headers: a coordinated RTP egress would be its own quest. The - demultiplexed export does not promise counter identity; matching them - there would need a dedicated PCR PID on every export. Aligning the legs in - time is a non-goal: each releases at its own first arrival plus the delay, - so their skew is the path difference, which a 2022-7 receiver absorbs. +- Passthrough gives 1+1 identity for free: two exporters fed the same + objects emit identical TS packets for every object both release, + continuity counters included, since passthrough never rewrites them; an + object one leg drops late is a gap in that leg only. Aligning the legs in + time is left to the `--sync` anchor planned for the demultiplexed export's + 2022-7 legs (`quest/m2/ts-hitless.md`, #4680), which passthrough can adopt. + That is TS identity, not ST 2022-7 recovery, which also needs matching RTP + headers from a coordinated RTP egress. - Rust only. `js/hang` does not parse `m2ts`, and a player sees no rendition for the track. - `--passthrough` publishes only the passthrough track. Publishing it