You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(subtitles): skip find_stream_info on the side demuxer to kill the ~5s PGS startup stall (#87)
The embedded-subtitle side demuxer needs only codec_id / codec_type, which
avformat_open_input resolves from the container header / MPEG-TS PMT. PGS/HDMV
bitmap tracks keep has_codec_parameters false to the probe cap (the #75 pattern),
so even the #76 5s analyze ceiling is paid in full on a remote URL source,
landing as a flat ~5s stall when the track is selected at load.
Add DemuxerOpenProfile.skipStreamInfo (set by subtitleSideDemuxer); probeStreams
drops the find_stream_info pass (and the cover-art reclassify, which only exists
to bound that pass) when set. The side reader runs a bounded resolveStreamInfo()
on demand only when its target stream's codec is genuinely unresolved at open (a
container that does not declare the subtitle codec in its header); the probe
ceiling still bounds that fallback pass.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XZTEfmztPE8hAdjHdBr9BH
Copy file name to clipboardExpand all lines: docs/architecture.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -126,7 +126,7 @@ Sources/AetherEngine/
126
126
│ ├── AVIOProvider.swift Internal seam over a custom-AVIO byte source; AVIOReader and CustomIOReaderBridge both plug into the Demuxer through it
127
127
│ ├── AVIOReader.swift URLSession-backed avio_alloc_context, three modes: persistent forward-streaming connection with reconnect-on-drop (playback, incl. live), discrete Range chunks (still extraction), single sequential GET with backpressure (non-live sources without Content-Length). Optional read deadline bounds a degenerate matroska Cues seek
128
128
│ ├── CustomIOReaderBridge.swift Bridges a host-supplied IOReader into avio_alloc_context read / seek callbacks
129
-
│ └── Demuxer.swift libavformat wrapper; seek + bounded seek (deadline-capped); per-open `DemuxerOpenProfile` budgets `find_stream_info` (probesize / max_analyze_duration), caller-overridable on the main playback open via `LoadOptions.probesize` / `maxAnalyzeDuration`
129
+
│ └── Demuxer.swift libavformat wrapper; seek + bounded seek (deadline-capped); per-open `DemuxerOpenProfile` budgets `find_stream_info` (probesize / max_analyze_duration), caller-overridable on the main playback open via `LoadOptions.probesize` / `maxAnalyzeDuration`. The subtitle side demuxer sets `skipStreamInfo` to drop the `find_stream_info` pass entirely (codec_id / codec_type come from the container header / PMT at open), so a PGS / bitmap track no longer chases the probe cap as a flat ~5 s startup stall on a remote URL source; the reader runs a bounded `resolveStreamInfo()` on demand only if its target stream's codec is genuinely unresolved at open (#87)
130
130
├── Diagnostics/
131
131
│ ├── EngineDiagnostics.swift engine.diagnostics: timer-sampled values (liveTelemetry) as a separate ObservableObject
132
132
│ ├── EngineLog.swift Gated OSLog emission with severity levels (.verbose suppressed from default + host handler)
0 commit comments