Skip to content

Use SourceBuffer timestampOffset rather than modify mp4 decode timestamps #5715

@robwalch

Description

@robwalch

Is your feature request related to a problem? Please describe.

HLS.js modifies MP4 (and remuxed TS) timestamps so that their PTS matches the desired playback timeline. This approach can be costly and result in issues (see history behind #5710).

Describe the solution you'd like

Instead, use MSE's SourceBuffer.timestampOffset to offset media.

Additional context

Special care should be taken to frame accuracy and video start gaps. Offsets related to audio priming delays or the MSE's handling of composition time are acceptable when unavoidable.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions