Skip to content

Improve audio video append sync#7842

Open
robwalch wants to merge 4 commits intomasterfrom
feature/improve-audio-video-append-sync
Open

Improve audio video append sync#7842
robwalch wants to merge 4 commits intomasterfrom
feature/improve-audio-video-append-sync

Conversation

@robwalch
Copy link
Copy Markdown
Collaborator

@robwalch robwalch commented May 7, 2026

This PR will...

Improve AV sync by fixing the use of block/unblock audio append operations in the buffer-controller.

  • Audio is considered blocked when the first operation in the audio queue is labeled 'block-audio' (replacing blockedAudioAppend)
  • Blocks each audio segment independently, releasing as video advances or moves back (seek)
  • Audio start does not need to be known to unblock
  • Audio blocking no longer requires an inflight video append
  • Audio blocking operations are always removed when executed; they only step forward and append audio when aligned with video (same as before)
  • Audio blocking is not stepped through by stepOperationQueue (called when resolving 'aync-block' operations)

Why is this Pull Request needed?

Improves audio/video buffer append cadence and alignment, preventing audio from playing ahead of video in browsers that allow that kind of thing.

Resolves issues:

Resolves #7808

Checklist

  • changes have been done against master branch, and PR does not conflict
  • new unit / functional tests have been added (whenever applicable)
  • API or design changes are documented in API.md

@robwalch robwalch added this to the 1.8.0 milestone May 7, 2026
@robwalch robwalch changed the title Feature/improve audio video append sync Improve audio video append sync May 7, 2026
@robwalch robwalch modified the milestones: 1.8.0, 1.7.0 May 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

playback interruptions when playing LL-HLS live stream with unstable network

1 participant