Vinyl
    Preparing search index...

    Interface SegmentReference<T>

    A reference, with metadata, to streaming and initialization data.

    interface SegmentReference<T> {
        data: T;
        endTime: number;
        initData: T;
        quality: MediaQualityMetadata;
        startTime: number;
        timestampOffset: number;
    }

    Type Parameters

    • T

    Hierarchy (View Summary)

    Index

    Properties

    data: T

    Provides the media data.

    endTime: number

    The end time of the segment, in seconds. Relative to the MPD timeline. Should be used as the append window end.

    initData: T

    References initialization data for this segment. Must be appended before data if the decoderId has changed from the last buffered segment. This is a shared reference between other streaming segments of the same quality/representation.

    Metadata describing the media encoding.

    startTime: number

    The start time of the segment, in seconds. Relative to the MPD timeline. Should be used as the append window start.

    timestampOffset: number

    The timestamp offset of the segment. Should be used as the append timestamp offset. This is in seconds, relative to the MPD timeline. For example if the first segment has a timestampOffset of -2 and startTime of 0, playback will begin 2s into the start of that segment.