feat(playback): report Embedded MPV file chapters on the timeline

Observe mpv `chapter-list` in the macOS and Windows addons and the
frame-copy helper, carry it as `EmbeddedMpvSession.chapters`, and map it
to `PlayerTimelineSegment[]` for `app-player-controls` when the host
passes no catch-up segments. A closing-credits chapter now times the
Up next card.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
4grayandClaude Opus 5.5 committed 2026-09-30 22:02:12 +02:00
1 parent 5f6e8b037f
commit 0b96fe70fa
24 files changed
+820 -5

No files matched your search

@@ -84,6 +84,13 @@ export interface EmbeddedMpvAudioTrack {
export type EmbeddedMpvSubtitleTrack = EmbeddedMpvAudioTrack;
/** One entry of mpv's `chapter-list`, in file order. */
export interface EmbeddedMpvChapter {
/** Chapter start, in media seconds. */
timeSeconds: number;
title?: string;
}
export interface EmbeddedMpvRecordingState {
active: boolean;
targetPath?: string;
@@ -142,6 +149,11 @@ export interface EmbeddedMpvSession {
selectedSubtitleTrackId: number | null;
playbackSpeed: number;
aspectOverride: string;
/**
* The file's chapters (mpv `chapter-list`). Absent from an addon built
* before chapters were observed and from the Linux `--wid` backend.
*/
chapters?: EmbeddedMpvChapter[];
/** Source video size (mpv dwidth/dheight); frame-copy engine only. */
videoWidth?: number;
videoHeight?: number;