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

"Seek over gap" feature seeks to first subtitle when subs are enabled #7310

Closed
joeyparrish opened this issue Sep 13, 2024 · 3 comments · Fixed by #7312 · May be fixed by #7257
Closed

"Seek over gap" feature seeks to first subtitle when subs are enabled #7310

joeyparrish opened this issue Sep 13, 2024 · 3 comments · Fixed by #7312 · May be fixed by #7257
Assignees
Labels
component: ads The issue involves the Shaka Player ads API or the use of other ad SDKs component: captions/subtitles The issue involves captions or subtitles component: DASH The issue involves the MPEG DASH manifest format platform: Cast Issues affecting Cast devices priority: P1 Big impact or workaround impractical; resolve before feature release type: bug Something isn't working correctly
Milestone

Comments

@joeyparrish
Copy link
Member

Have you read the FAQ and checked for duplicate open issues?
Yes

If the problem is related to FairPlay, have you read the tutorial?

N/A

What version of Shaka Player are you using?

4.9.2 (CAF)

Can you reproduce the issue with our latest release version?
Yes

Can you reproduce the issue with the latest code from main?
Yes

Are you using the demo app or your own custom app?
Custom app

If custom app, can you reproduce the issue using our demo app?
Didn't try in this case, because I have already found the root cause

What browser and OS are you using?
Chromecast

For embedded devices (smart TVs, etc.), what model and firmware version are you using?
Chromecast w/ Google TV (Android-based, latest production firmware)

What are the manifest and license server URIs?

Using a partner's receiver app

What configuration are you using? What is the output of player.getConfiguration()?

Default

What did you do?

Start content with subtitles enabled

What did you expect to happen?
Content plays from 0, including pre-roll ads

What actually happened?

Content plays from the first subtitle, which leads to skipping the pre-roll ad

Are you planning send a PR to fix it?
Yes

@joeyparrish joeyparrish added type: bug Something isn't working correctly component: captions/subtitles The issue involves captions or subtitles component: ads The issue involves the Shaka Player ads API or the use of other ad SDKs priority: P1 Big impact or workaround impractical; resolve before feature release component: DASH The issue involves the MPEG DASH manifest format platform: Cast Issues affecting Cast devices labels Sep 13, 2024
@joeyparrish joeyparrish self-assigned this Sep 13, 2024
@shaka-bot shaka-bot added this to the v4.12 milestone Sep 13, 2024
@joeyparrish
Copy link
Member Author

I figured out the root cause, and I have a fix that does not require reverting the PR that introduced it (#6340).

The logic introduced in the PR looks roughly like this:

if (!live &&
    paused &&
    startTimeOfFirstSegment > 0 &&
    playhead < startTimeOfFirstSegment) {
  skipAhead();
}

The problem is that the start time of the first segment of text is non-zero. Seeking over an initial gap fixed real content issues, but it makes no sense to seek over a gap in text, so we should simply exclude text segments from this check.

@joeyparrish
Copy link
Member Author

joeyparrish commented Sep 13, 2024

The bug affects v4.6.16-18, v4.7.12-15, v4.8.0-20, v4.9.0-26, v4.10.0-16, and v4.11.0-2.

@joeyparrish
Copy link
Member Author

v4.6, v4.7, and v4.8 are no longer maintained and will not get a cherry-picked fix.

joeyparrish added a commit to joeyparrish/shaka-player that referenced this issue Sep 13, 2024
The bug was introduced in shaka-project#6340, and affects v4.6.16-18, v4.7.12-15,
v4.8.0-20, v4.9.0-26, v4.10.0-16, and v4.11.0.

Closes shaka-project#7310
joeyparrish added a commit that referenced this issue Sep 13, 2024
The bug was introduced in #6340, and affects v4.6.16-18, v4.7.12-15,
v4.8.0-20, v4.9.0-26, v4.10.0-16, and v4.11.0.

Closes #7310

Release-As: 4.9.2-caf1
joeyparrish added a commit that referenced this issue Sep 13, 2024
The bug was introduced in #6340, and affects v4.6.16-18, v4.7.12-15,
v4.8.0-20, v4.9.0-26, v4.10.0-16, and v4.11.0.

Closes #7310
joeyparrish added a commit that referenced this issue Sep 13, 2024
The bug was introduced in #6340, and affects v4.6.16-18, v4.7.12-15,
v4.8.0-20, v4.9.0-26, v4.10.0-16, and v4.11.0.

Closes #7310

Release-As: 4.9.2-caf1
joeyparrish added a commit that referenced this issue Sep 13, 2024
The bug was introduced in #6340, and affects v4.6.16-18, v4.7.12-15,
v4.8.0-20, v4.9.0-26, v4.10.0-16, and v4.11.0.

Closes #7310
joeyparrish added a commit that referenced this issue Sep 13, 2024
The bug was introduced in #6340, and affects v4.6.16-18, v4.7.12-15,
v4.8.0-20, v4.9.0-26, v4.10.0-16, and v4.11.0.

Closes #7310
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: ads The issue involves the Shaka Player ads API or the use of other ad SDKs component: captions/subtitles The issue involves captions or subtitles component: DASH The issue involves the MPEG DASH manifest format platform: Cast Issues affecting Cast devices priority: P1 Big impact or workaround impractical; resolve before feature release type: bug Something isn't working correctly
2 participants