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

iOS - textTracks #1210

Closed
enricovittorini opened this issue Sep 27, 2021 · 5 comments
Closed

iOS - textTracks #1210

enricovittorini opened this issue Sep 27, 2021 · 5 comments
Labels

Comments

@enricovittorini
Copy link

enricovittorini commented Sep 27, 2021

Please do not delete the template, by filling out the required information we can investigate your issue more quickly.

Before opening an issue see if your problem can be resolved with the troubleshooting guide.

Description

in my code:
the options for the player are:

      var options = {
           preload: 'auto',
           live: true,
           liveui: true,
           liveTracker: true,
           controls: false,
           muted: true,
           //enableLowInitialPlaylist: true,
           html5: {
               autoplay: true,
               vhs: {
                   overrideNative: true
               },
               nativeAudioTracks: false,
               nativeVideoTracks: false,
               nativeTextTracks: false
           },

       };
let tracks = player1.textTracks();
let str = tracks[0].activeCues[0].value.uri

if I alert "str" on iPad, the result is undefined. While it is working well on windows or android.

I think is the same issue as #214. any solution on this?

Sources

Steps to reproduce

Results

Expected

Error output

no error

Additional Information

Please include any additional information necessary here. Including the following:

videojs-http-streaming version

what version of videojs-http-streaming does this occur with?
videojs-http-streaming x.y.z

videojs version

what version of videojs does this occur with?
video.js x.y.z

Browsers

what browsers are affected? please include browser and version for each
*

Platforms

what platforms are affected? please include operating system and version or device and version for each
*

Other Plugins

are any other videojs plugins being used on the page? If so, please list them with version below.
*

Other JavaScript

are you using any other javascript libraries or frameworks on the page? if so please list them below.
*

@welcome
Copy link

welcome bot commented Sep 27, 2021

👋 Thanks for opening your first issue here! 👋

If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.
To help make it easier for us to investigate your issue, please follow the contributing guidelines.

@gkatsev
Copy link
Member

gkatsev commented Sep 27, 2021

It should be able to work on ipad assuming you're on a recent enough version of ipados. However, it won't work on iphones as MSE, the API that we rely on, isn't available.
Though, just tried https://videojs-http-streaming.netlify.app/ on my ipad and I don't see segment-metadata show up under player stats tab panel. Though, that page isn't overriding the text tracks.

@enricovittorini
Copy link
Author

thanks for your answer.
is there a way to get the current played segment on iOS?

@gkatsev
Copy link
Member

gkatsev commented Sep 27, 2021

So, I think if you set the mode of the track to 'hidden' as early as possible, it should work.

const tracks = player.textTracks();
// assuming that segment-metadata is the first track, it could potentially not be
tracks[0].mode = 'hidden';

Afterwards, it should work.

@stale
Copy link

stale bot commented Jan 8, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the outdated label Jan 8, 2022
@stale stale bot closed this as completed Apr 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants