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 tracks #66

Open
dairondv1986 opened this issue Jun 2, 2020 · 5 comments
Open

iOS tracks #66

dairondv1986 opened this issue Jun 2, 2020 · 5 comments

Comments

@dairondv1986
Copy link

Hi, I recently download the latest code (98edc9e) and the problem is that no tracks are received in javascript Media object. I started debug inside iOS code then i found that the code is commented at line 683 inside getMediaTracks's method, I think it's because of an error when creating the array of tracks. Then I try to fixed then I see the problem was [MLPCastUtilities getTextTrackSubtype:mediaTrack.textSubtype] when textSubtipe is 0 (Unknown) the method getTextTrackSubtype return nil because of default return inside switch. Thanks.

@Lindsay-Needs-Sleep
Copy link
Collaborator

Sorry for the slow response, very busy right now (and for the next few months).

Thank you for the bug report and your investigation! This sounds familiar, I do believe I just commented it out because it was causing problems and I didn't have a way to test it.

I don't know much about the tracks, do you know how I can test it?
eg.

  • Do the subtitles need to be embed in the video already, or do they come from a separate url?
  • Do you have any urls that I can use for testing?

You could try the code from PR #63. There is a good chance it is fixed there.

@dairondv1986
Copy link
Author

dairondv1986 commented Oct 23, 2020

Hi, sorry for the ultra slow response, very busy too with releases jej, look i just replace the commented code with this one i put next and everything is working fine, at least i receive all tracks send by the chromecast.
for (GCKMediaTrack* mediaTrack in mediaTracks) { NSDictionary* track = @{ @"trackId": @(mediaTrack.identifier), @"customData": mediaTrack.customData == nil? @{} : mediaTrack.customData, @"language": mediaTrack.languageCode == nil? @"" : mediaTrack.languageCode, @"name": mediaTrack.name == nil? @"" : mediaTrack.name, @"subtype": [MLPCastUtilities getTextTrackSubtype:mediaTrack.textSubtype] != nil ? [MLPCastUtilities getTextTrackSubtype:mediaTrack.textSubtype] : @"", @"trackContentId": mediaTrack.contentIdentifier == nil ? @"" : mediaTrack.contentIdentifier, @"trackContentType": mediaTrack.contentType == nil ? @"" : mediaTrack.contentType, @"type": [MLPCastUtilities getTrackType:mediaTrack.type], }; if(track != nil) { [tracks addObject:track]; } }

Sorry i cant share url's for testing but i can test and send to you reports. About the subtitles does not matter if come embed inside the video or come with external urls, I already test it with both of it's working fine.

@Lindsay-Needs-Sleep
Copy link
Collaborator

Better late than never! :D

Thank you for the offer to test and the info!

I really would like to be able to include a test for this in the test suite though as well. (To prevent any future error regression).

I understand you can't supply any urls for testing, that's okay, I can try and find a way around that later.

Could you show me a sample of the javascript you use to load media that has tracks (1 for embeded and 1 for external)? (with the urls removed of course) This would help with writing the test!

@dairondv1986
Copy link
Author

dairondv1986 commented Nov 3, 2020 via email

@Lindsay-Needs-Sleep
Copy link
Collaborator

Thank you for the sample code!
And for the additional details!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants