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

ignore timeupdates while seeking #8

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

Topsii
Copy link

@Topsii Topsii commented Sep 26, 2017

I was working with high bitrate videos that take some time to load. I noticed that when seeking to some position the seeked subtitles appeared instantly while the player (videojs dash in my case) was stopped at the current frame prior seeking. Even worse the subtitles at the seeked position were playing (and would only stop after 5 seconds of not receiving update events iirc).

This fix ignores timeupdates while seeking to keep the videoimage and subtitles consistent.

@Dador
Copy link
Collaborator

Dador commented Oct 3, 2017

Isn't it better to just call self.setIsPaused in seeking/seeked event listener?
I didn't checked it yet, but looking at code it seems problem with "continue to play for 5 seconds while seeking" will remain, because you just remove sending new time to worked but don't pause the video.

@Dador
Copy link
Collaborator

Dador commented Jan 1, 2018

Can't confirm the issue. Please re-open with more details if you still experience the issue.

@Dador Dador closed this Jan 1, 2018
@Topsii
Copy link
Author

Topsii commented Jan 6, 2018

This commit did indeed not fix the problem.

When seeking to some position the subtitles appear immediately, even if the video-image of that position has not yet loaded. But in my opinion subtitles should only appear together with the corresponding video-image.

IIRC setIsPaused can only stop subtitles at the seek-destination, but not at the seek-origin.

As mentioned to experience this problem loading times when seeking have to be high.

What other details do you need?

@Dador
Copy link
Collaborator

Dador commented Jan 10, 2018

Thank you for explanation.

I thought you did a fix for issue "subtitles playing even after seeking" that you mentioned in first message, but now I understand. Anyway, sorry for misunderstanding :)

@Dador Dador reopened this Jan 10, 2018
@joshuabrown-ellation
Copy link

Yes please. This would be helpful. We could hack it by suspending the tick on animation frame on our code, but this would be a good feature add.

JustAMan added a commit to JustAMan/JavascriptSubtitlesOctopus that referenced this pull request Mar 25, 2020
Add "lite render" mode when all animations are disabled
@ThaUnknown ThaUnknown mentioned this pull request Apr 27, 2022
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.

None yet

3 participants