Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playback start for SegmentBase streams #3322

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/streaming/Stream.js
Expand Up @@ -633,6 +633,11 @@ function Stream(config) {
streamInfo: streamInfo,
liveStartTime: getLiveStartTime()
});

// Start ScheduleController in case stream initialization has been completed after 'play' event (case for SegmentBase streams)
for (let i = 0; i < ln && streamProcessors[i]; i++) {
streamProcessors[i].getScheduleController().start();
}
}
}

Expand Down
5 changes: 1 addition & 4 deletions src/streaming/controllers/PlaybackController.js
Expand Up @@ -135,12 +135,9 @@ function PlaybackController() {
startTime = Math.max(startTime, startTimeFromUri);
}
}

// Check if not seeking at current time
if (startTime === videoModel.getTime()) return;
}

if (!isNaN(startTime)) {
if (!isNaN(startTime) && startTime !== videoModel.getTime()) {
// Trigger PLAYBACK_SEEKING event for controllers
eventBus.trigger(Events.PLAYBACK_SEEKING, {
seekTime: startTime
Expand Down