Repository navigation
Conversation
An independent video clock advances while audio fills its output pipeline or stalls. Use the reported audio position when available and keep it monotonic. If audio ends, resume from the last observed position so the picture does not jump ahead or stall.
Video used elapsed wall time to choose frames, so a large audio output delay could put the picture and subtitles ahead of the sound. Use the audio playback position when available and continue on elapsed time when video plays without audio or outlasts it. Use the frame count as the exclusive end for full playback so the last frame can be displayed before playback stops.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Video preview advanced on its own wall clock. When audio took longer to start or stalled, the picture and subtitles could get ahead of the sound.
Use the audio player's reported position to schedule video frames. When audio is unavailable or ends before the picture, continue on elapsed time from the last position. Full playback now also displays the final frame.
Tested with a macOS build and the Meson test suite, including regression coverage for delayed audio startup, stalls, and the transition to silent playback.
🤖 Codex