ebiten
ebiten copied to clipboard
audio: remove a hack using a dummy player
Operating System
- [ ] Windows
- [ ] macOS
- [ ] Linux
- [ ] FreeBSD
- [ ] OpenBSD
- [ ] Android
- [ ] iOS
- [ ] Nintendo Switch
- [ ] Xbox
- [ ] Web Browsers
What feature would you like to be added?
There is a hack using a dummy player to make the context ready. Actually, without this hack, examples/pcm doesn't work on browsers. I think this hack was introduced when Oto was not separated yet. See also #969, #970.
This hack should be on the Oto side rather than Ebitengine for every Oto user's benefits.
Why is this needed?
No response
The hack was needed not only for browsers but also every platform, maybe
OK I found this is due to Ebitengine's implementation, rather than Oto. Let's do refactoring anyway...
This requires more refactoring the audio package.
https://github.com/hajimehoshi/ebiten/blob/9cc017412fe41350b78534e24ee2ed20045d37e8/audio/audio.go#L288-L299