Add skipInitialTimeSet to prevent seeking on live streams#27
Open
jaumecornado wants to merge 1 commit intoLePips:mainfrom
Open
Add skipInitialTimeSet to prevent seeking on live streams#27jaumecornado wants to merge 1 commit intoLePips:mainfrom
jaumecornado wants to merge 1 commit intoLePips:mainfrom
Conversation
setConfigurationValues unconditionally sets player.time to startTime (default 0) the first time playback ticks advance. For VOD content this is correct, but for live HLS streams with timeshift buffers it causes VLC to seek away from the live edge, triggering a long rebuffer (observed 3+ minutes) or playback starting hours behind real-time. Adding a `skipInitialTimeSet` flag on Configuration lets callers opt out of the initial time assignment. When set to `true`, VLC keeps the position it naturally chose (the live edge), and the rest of setConfigurationValues (rate, subtitles, audio, aspect fill) still applies normally. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Summary
skipInitialTimeSet: Boolproperty toConfiguration(defaultfalse, no breaking changes)true,setConfigurationValuesskips theplayer.time =assignment, preventing VLC from seeking away from the live edge on live HLS streamsFixes #26
Problem
setConfigurationValuesunconditionally setsplayer.time = startTime(default.ticks(0)) the first time playback advances. For live HLS streams with timeshift buffers, this causes:setConfigurationValuesseeks to position 0 (start of timeshift buffer)Even setting
startTimeto the current position causes VLC to flush buffers and rebuffer, because anyplayer.time = Xcall triggers a seek in VLCKit.Test plan
skipInitialTimeSet = truestarts at live edge without rebufferingskipInitialTimeSet = false(default) behaves unchangedstartTimestill seeks correctly🤖 Generated with Claude Code