mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-26 03:38:55 +01:00
audio/internal/readerdriver: Refactoring: EOF doesn't matter to determine when to stop the waiting
This commit is contained in:
parent
7f8648f133
commit
81015a3c19
@ -651,7 +651,7 @@ func (p *playerImpl) shouldWait() bool {
|
||||
case playerPaused:
|
||||
return true
|
||||
case playerPlay:
|
||||
return len(p.buf) >= p.context.maxBufferSize() || p.eof
|
||||
return len(p.buf) >= p.context.maxBufferSize()
|
||||
case playerClosed:
|
||||
return false
|
||||
default:
|
||||
|
@ -341,7 +341,7 @@ func (p *player) shouldWait() bool {
|
||||
// WebAudio doesn't have a notion of pause.
|
||||
return false
|
||||
case playerPlay:
|
||||
return len(p.buf) >= p.context.maxBufferSize() || p.eof
|
||||
return len(p.buf) >= p.context.maxBufferSize()
|
||||
case playerClosed:
|
||||
return false
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user