mirror of
https://github.com/samsonjs/media.git
synced 2026-03-27 09:45:47 +00:00
While buffering check for errors even if renderes are ready.
On an edge case, player may get stuck when the renderers are ready but the buffer doesn't get full enough because of a fatal error in data source. An example state can be created by starting a live DASH stream and switching between normal and slow network connections. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=129084824
This commit is contained in:
parent
9a272068b4
commit
bd7c8fed1b
1 changed files with 6 additions and 0 deletions
|
|
@ -470,6 +470,12 @@ import java.util.ArrayList;
|
|||
}
|
||||
}
|
||||
|
||||
if (state == ExoPlayer.STATE_BUFFERING) {
|
||||
for (Renderer renderer : enabledRenderers) {
|
||||
renderer.maybeThrowStreamError();
|
||||
}
|
||||
}
|
||||
|
||||
handler.removeMessages(MSG_DO_SOME_WORK);
|
||||
if ((playWhenReady && state == ExoPlayer.STATE_READY) || state == ExoPlayer.STATE_BUFFERING) {
|
||||
scheduleNextOperation(MSG_DO_SOME_WORK, operationStartTimeMs, RENDERING_INTERVAL_MS);
|
||||
|
|
|
|||
Loading…
Reference in a new issue