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

Videojs: 0.4.1.1: hls_startfromlevel=0 playing audio version, not lowest non-audio #358

Closed
tommyh opened this issue Aug 5, 2015 · 1 comment

Comments

@tommyh
Copy link

tommyh commented Aug 5, 2015

When I set hls_startfromlevel=0 the player is playing the lowest bitrate version (ie the 64k audio), but it's not playing the "lowest non-audio bitrate" version.

Expected behavior: hls_startfromlevel=0 should result in a video level to play.
Actual behavior: hls_startfromlevel=0 results in the audio level playing.

Page to reproduce: http://rawgit.com/tommyh/7cb64812be249660e8bd/raw/d45b964ed8ab3109375a7b65e63de7651876ec27/hls_startfromlevel_0.html

My m3u8 file is:

#EXTM3U
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=2040000
272deb0e2c488b98-2040k.m3u8
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=1540000
272deb0e2c488b98-1540k.m3u8
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=1040000
272deb0e2c488b98-1040k.m3u8
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=640000
272deb0e2c488b98-640k.m3u8
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=440000
272deb0e2c488b98-440k.m3u8
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=240000
272deb0e2c488b98-240k.m3u8
#EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=64000
272deb0e2c488b98-64k.m3u8

Does this issue mean:

  • my m3u8 file isn't giving enough data to flashls to distinguish an audio level vs a video level? (ie: do I need to set a CODECS attribute?)
  • the m3u8 file is fine but there is an issue in flashls where it is incorrectly processing the levels and thinks the 64k stream has video?

Note 1: Our hls video is being encoded by zencoder, if that makes a difference.

Note 2: To make sure #351 is not messing up my test for hls_startfromlevel I have also made a page with hls_startfromlevel=1 and that page appears to function correctly by giving the highest bitrate channel: http://rawgit.com/tommyh/7cb64812be249660e8bd/raw/d45b964ed8ab3109375a7b65e63de7651876ec27/hls_startfromlevel_1.html

@mangui
Copy link
Owner

mangui commented Aug 17, 2015

flashls will use the level you asked for ... if you hardcode startlevel to 0, the lowest bitrate will be used. and if level 0 is audio only,

you should better not configure startLevel (or set it to -1) to let flashls decide and avoid such kind of issues.
also, as you didn't set the CODECS attribute, there is no way flashls could guess that level 0 is audio-only ...
plz refer to the logic here
https://github.com/mangui/flashls/blob/dev/src/org/mangui/hls/controller/LevelController.as#L301-L346

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

No branches or pull requests

2 participants