@byomakase/omakase-player
    Preparing search index...

    Class BaseSidecarTrackController<D>Abstract

    Plays sidecar in its own SidecarDomController, synced with main media.

    Main media is the master clock. Main media time is mapped to sidecar time through SidecarTimeWindow. Base controller resolves time window position, warm-up, visibility, residency and whether main media has to wait for sidecar. Playing, pausing and seeking sidecar media is left to subclass, see syncPlayback.

    Sidecar element has its source attached only while main media time is near its time window, from SidecarTrackControllerConfig.wakeAhead before warm-up to SidecarTrackControllerConfig.keepAwakeAfter after time window. Elsewhere sidecar is dormant, source is released, so many sidecars on main media timeline don't hold decoders, network and buffers. Dormant active sidecar inside its time window is woken up and main media waits for it. Number of sidecars awake at once is limited by SidecarTrackControllerConfig.awakeBudget, sidecars closer to main media time take precedence.

    First load needs sidecar duration, to validate time window:

    • duration known from track state - nothing is loaded, sidecar starts dormant
    • SidecarTrackControllerConfig.metadataLoad - only duration is loaded, sidecar starts dormant
    • otherwise - media is loaded from first sidecar time to be played, sidecar starts awake

    Type Parameters

    Hierarchy (View Summary)

    Implements

    Index

    Accessors

    Methods