http-streaming icon indicating copy to clipboard operation
http-streaming copied to clipboard

Subtitles dont load on smarttv by hls

Open qwaszx000 opened this issue 2 years ago • 5 comments

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

Description

When using overrideNative: false to create player, player dont shows and loads any subtitles(player.textTracks().length = 0) So even captions menu/button dont shows

However using overrideNative: true shows subtitles, but i cant use it becase of using hls with hevc and avc videos, and with this option hevc video dont works. So i am forced to use overrideNative: false

Why using videojs.browser.IS_ANDROID? Because using overrideNative: false leads to problems, this m3u8 file dont works absolutely

I am ready to help with debuging, fixing and testing this problem If there is need - i can tell my friend to check something using his smarttv device

Sources

https://files.cinemahd.box.ca/hls/video_hevc_output20/master.m3u8 Consists of hevc video, avc video, 1 audio and 3 subtitle files(webvtt) m3u8 generated by bento4's mp4dash --hls

Steps to reproduce

  1. Create videojs player with <source src="https://files.cinemahd.box.ca/hls/video_hevc_output20/master.m3u8" type="application/x-mpegURL"/>
  2. Initiate it with: player = videojs("player", { html5: { vhs: { overrideNative: videojs.browser.IS_ANDROID, }, } });
  3. Check player with "SmartTV/10.0 Cold/2.0"

Results

Hevc and avc video plays, subtitles do not appearing only on smarttv(PC windows and linux, android and iphone - subtitles shows)

Expected

Showing subtitles on smarttv with overrideNative: false Or working hevc with overrideNative: true on smarttv

Error output

No any errors except "Script error", which i dont know why appears, cuz all scripts on my host, so i think i should catch real error, but not "Script error" Because of complicated debug poccess(catching errors through redefining console log, error and warn, videojs.log and window.onerror functions and showing info in h1 tag because i dont have direct access to this smarttv device) i really cant debug it in normal meaning and can only guess

Additional Information

Using overrideNative: true cures this problem, but then i cant change video quality to hevc(plugin httpSourceSelector). If i use overrideNative: false, i can change video quality to hevc(using same plugin and same settings except overrideNative) and dont get error(QUOTA_EXCEEDED_ERR).

Tried to fix QUOTA_EXCEEDED_ERR with setting videojs.Hls.MAX_GOAL_BUFFER_LENGTH = 30; videojs.Vhs.MAX_GOAL_BUFFER_LENGTH = 30; Didnt helped

videojs-http-streaming version

"@videojs/http-streaming": "2.13.1" ​"aes-decrypter": "3.1.2" ​"m3u8-parser": "4.7.0" "mpd-parser": "0.21.0" "mux.js": "6.0.1"

videojs version

video.js 7.18.0

httpSourceSelector version

According to var version = "1.1.6"; - 1.1.6

videojs-contrib-quality-levels version

2.1.0

Browsers

Smarttv, any browser

Platforms

Smarttv

Other Plugins

httpSourceSelector(https://github.com/jfujita/videojs-http-source-selector) https://github.com/videojs/videojs-contrib-quality-levels

Other JavaScript

No

qwaszx000 avatar May 16 '22 12:05 qwaszx000

Hey! We've detected some video files in a comment on this issue. If you'd like to permanently archive these videos and tie them to this project, a maintainer of the project can reply to this issue with the following commands:

  • for https://files.cinemahd.box.ca/hls/video_hevc_output20/master.m3u8: say @video-archivist-bot save ZA5gkj

video-archivist-bot avatar May 16 '22 12:05 video-archivist-bot

👋 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.

welcome[bot] avatar May 16 '22 12:05 welcome[bot]

изображение

Example of my debugging process Here you can see some logs of videojs and plugins Type errors because player.textTracks().length == 0

qwaszx000 avatar May 16 '22 12:05 qwaszx000

Hi @qwaszx000 , thank you for the detailed report.

With overrideNative set to false, we have no control over the player (as it uses the native player).

With overrideNative set to true, you mentioned that you are seeing QUOTA_EXCEEDED_ERR. This usually is an issue when the device has a very limited amount of memory dedicated to the media buffer, and the segment sizes are too large. The included m3u8 seems to be 404ing for me, but have you tried with smaller segment sizes (and lower bitrates)?

gesinger avatar May 25 '22 19:05 gesinger

Hello @gesinger Yeah, friend deleted all test dirs without asking me No, we didn't tried with smaller segment sizes(m3u8 generated with bento4, so we use segment sizes, selected by mp4dash with --hls option) Our goal was to play hevc video, and hevc video means hight bitrate, so about lower bitrates - also can't say anything

Now i can say that dash file with just const player = videojs("video_selector"); and specifying dash file in <source src="" type="application/x-mpegURL"> works pretty well, and we'll use it

qwaszx000 avatar May 26 '22 07:05 qwaszx000