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

buffer ahead for live stream #1054

Closed
kuznetcoff777 opened this issue Oct 5, 2017 · 5 comments
Closed

buffer ahead for live stream #1054

kuznetcoff777 opened this issue Oct 5, 2017 · 5 comments
Labels
status: archived Archived and locked; will not be updated type: question A question from the community

Comments

@kuznetcoff777
Copy link

Have you read the FAQ and checked for duplicate issues: yes

What version of Shaka Player are you using: latest

Can you reproduce the issue with our latest release version:yes

Can you reproduce the issue with the latest code from master: yes

Are you using the demo app or your own custom app: custom

If custom app, can you reproduce the issue using our demo app: yes

What browser and OS are you using: chrome

What are the manifest and license server URIs: sent to gmail
(you can send the URIs to [email protected] instead, but please use GitHub and the template for the rest)

What did you do? Opened live stream with suggestet presentation delay = 20s
checked how buffer worked, it fetches 20-30 seconds ahead, as just described in #1051.
After that i changed suggested presentation delay to 60, reloaded player, saw that delay between player time and real time is about 60s (as just expected) but player still fetches the same 20-30 seconds ahead, but supposed to fetch ~60 seconds ahead.

@kuznetcoff777
Copy link
Author

One thing i also cannot understand. What if we have big timeShiftBufferDepth and we paused for several minutes. What time will player buffer ahead? Still the same supposed suggested presentation delay?

@joeyparrish
Copy link
Member

We never buffer more than bufferingGoal + 1 segment. For 10s segments and 20s bufferingGoal, that could be up to 30s.

We can't reach bufferingGoal if the content is not available. Video's currentTime, mpd's timeShiftBufferDepth, and mpd's suggestedPresentationDelay all affect what is available. If you are less than N seconds from the end of what is available from the server, you can't buffer N seconds of content.

The timeShiftBufferDepth and suggestedPresentationDelay attributes don't affect buffering goals, but do dictate what is available to buffer.

What is your player configuration? The default bufferingGoal is 30s, if I recall correctly.

@joeyparrish
Copy link
Member

Once we have your configuration, we will attempt to reproduce and explain what is happening.

@joeyparrish joeyparrish added the status: waiting on response Waiting on a response from the reporter(s) of the issue label Oct 5, 2017
@kuznetcoff777
Copy link
Author

kuznetcoff777 commented Oct 6, 2017

The same issue i got on demo app.
My config is
streaming:
bufferBehind:30
bufferingGoal:10
failureCallback:ƒ ()
ignoreTextStreamFailures:false
jumpLargeGaps:false
rebufferingGoal:2
retryParameters:{maxAttempts: 2, baseDelay: 1000, backoffFactor: 2, fuzzFactor: 0.5, timeout: 0}
smallGapLimit:0.5
startAtSegmentBoundary:true

So it seems to I made wrong conclusion from #1051.

So now as i understand - when we watch very live content - only suggested presentation delay is active, so player can fetch only that segments which is in presentation delay time (maybe +1 segment)

But when we paused (and buffer depth is huge) for a couple of minutes, if only buffering goal is active in this case? If we configure buffering goal = 10 seconds, then player can fetch bufferingGoal + 1 segment.

If everyting i described correctly?

@joeyparrish joeyparrish removed the status: waiting on response Waiting on a response from the reporter(s) of the issue label Oct 7, 2017
@TheModMaker
Copy link
Contributor

@kuznetcoff777 That is correct. We will buffer up to bufferingGoal + 1 segment. So in your case, we will only buffer 30 seconds of content plus up to a partial segment. If you're close to the live edge, there will only be suggestedPresentationDelay amount of content available, so we don't have any more content to buffer.

Also note that you may need to reload the asset if you change the suggestedPresentationDelay.

@joeyparrish joeyparrish added type: question A question from the community and removed needs triage labels Oct 10, 2017
@shaka-project shaka-project locked and limited conversation to collaborators Mar 22, 2018
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Apr 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: archived Archived and locked; will not be updated type: question A question from the community
Projects
None yet
Development

No branches or pull requests

4 participants