Skip to content

Fix HLS audio initialization and avoid reloading during player recovery - #213

Merged
ralyodio merged 1 commit into
mainfrom
fix/player-recovery-notices
Sep 15, 2026
Merged

ralyodio merged 1 commit into
mainfrom
fix/player-recovery-notices

Conversation

@ralyodio

Copy link
Copy Markdown
Contributor

The production browser check exposed AAC headers missing from newly normalized fragmented MP4. Video frames decoded in FFmpeg, but remuxing that stream into HLS could produce invalid AAC packets and trigger repeated browser recovery. Delay the initial MP4 header until the AAC bitstream filter has produced its audio configuration.

Keep transient engine recovery separate from the room's terminal-error/rejoin handling, including MediaSource-aborted play requests. Also avoid retaining an extra fragment at the six-second buffer boundary due to timestamp rounding.

Validation: real course excerpts now play through HLS without decoding errors; a new automated browser test decodes red/blue/green video and audio across three files and mixed source codecs. AAC initialization headers and transient-versus-terminal player recovery have regression tests. Type checks and builds pass.

@ralyodio
ralyodio merged commit 6f83ff3 into main Sep 15, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant