Navigation Menu

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

What is maxMaxBufferLength? #58

Closed
shaharmor opened this issue Nov 9, 2015 · 1 comment
Closed

What is maxMaxBufferLength? #58

shaharmor opened this issue Nov 9, 2015 · 1 comment
Labels

Comments

@shaharmor
Copy link
Contributor

I don't mean maxBufferLength, but maxMaxBufferLength

@mangui
Copy link
Member

mangui commented Nov 9, 2015

as you can see here,
https://github.com/dailymotion/hls.js/blob/d0319d7b690fabb9283f2b82b0917b7a204d3fb4/src/controller/buffer-controller.js#L175-L176

hls.js tries to buffer up to a maximum number of bytes (60 MB by default) rather than to buffer up to a maximum nb of seconds.
this is to mimic the browser behaviour (the buffer eviction algorithm is starting after the browser detects that video buffer size reaches a limit in bytes)

config.maxBufferLength is the minimum guaranteed buffer length that hls.js will try to achieve, even if that value exceeds the amount of bytes 60 MB of memory.
maxMaxBufferLength acts as a capping value, as if bitrate is really low, you could need more than one hour of buffer to fill 60 MB....

=> the max buf length hls.js will try to achieve will always be between [config.maxBufferLength,config,maxMaxBufferLength]

I agree that renaming those variables would help ...
maybe config.maxBufferLengthMin and config.maxBufferLengthMax ...
any suggestion welcomed ...

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