AutoMovie API
    Preparing search index...

    Class AutoMovieInspectorPlayhead

    The inspector's playhead: the second shown, the subject's duration, whether it plays and how fast, kept outside React.

    The render loop advances it and reads it directly every frame. The time readout reads its snapshot through useSyncExternalStore with subscribe and getSnapshot, and the time panel only whether it plays, so a playing frame re-renders the readout alone and a start or stop also the panel's play button. A snapshot is replaced, never changed, so its identity tells a reader whether anything moved. Seconds stay within [0, durationSeconds].

    The rate scales how fast the preview plays and is not part of the request: it changes no picture, and the capture grammar's rate key, stills per second, is a different quantity.

    const seconds = useSyncExternalStore(playhead.subscribe, playhead.getSnapshot).seconds;
    
    Index
    getSnapshot: () => AutoMovieInspectorPlayhead.ISnapshot = ...

    The current snapshot, the same object until something changes.

    subscribe: (listener: () => void) => () => void = ...

    Call listener after every change, until the returned function is called.

    • Set the subject's duration when an instance is ready, keeping the second within it.

      It throws for a duration that is not a positive finite number.

      Parameters

      • durationSeconds: number

      Returns void