Fixed
- Fix: Keep looping after pause and resume (#353, backport of #352) @zbdd
- Fix: Resume audio on the next tap after iOS stops it (#351, backport of #349) @zbdd
- Fix: Keep the paused state on a focus with no blur (#350, backport of #348) @zbdd
- Fix: Auto-pause on tab switch after the first click (#346, backport of #344) @zbdd
- Fix: Load once when play() comes before load (#345, backport of #342) @zbdd
- Fix: Resume after a pause in the same tick (#343, backport of #340) @zbdd
- Fix: Name and log file in decode errors (#336, backport of #330) @zbdd
- Fix: Report a decode error to the loaded callback only once (#328, backport of #326) @zbdd
- Fix: Return NaN for the duration of a sound that hasn't loaded (#327, backport of #325) @zbdd
- Fix: Report fetch and HTTP errors when loading a sound (#324, backport of #291) @zbdd
- Fix: Catch fetch errors when loading a sound (#280) @Sprutik
- Fix: Resolve every AssetPack alias for a sound (#323, backport of #285) @zbdd
- Fix: Respect the play speed for sprites (#322, backport of #319) @zbdd
- Fix: Ignore undefined options instead of overriding the defaults (#320, backport of #317) @ColumbusLabs
- Fix: Treat an undefined start as zero when playing a sound (#316, backport of #314) @voidsipp
- Chore: Put types first in the package exports (#338, backport of #332) @zbdd
Docs
- Chore: Replace the README browser list with PixiJS v7 support (#362, backport of #354) @zbdd
- Chore: Document how to write a custom filter (#363, backport of #361) @zbdd
- Chore: Document that global options override local ones in add (#321, backport of #318) @zbdd
Heads up
If you suspend the AudioContext yourself, the next tap now resumes it (#351). To pause, use sound.pauseAll() or sound.context.paused.
resumeAll() followed by pauseAll() in the same tick now leaves the audio suspended (#343). Before, it kept running while paused. playEmptySound() no longer starts the audio context while sounds are paused (#346).
On WebAudio, a failed request now rejects Assets.load and calls loaded with an error naming the URL (#324). Before, a network error left the load unsettled and an HTTP error came back as a decode error. A Sound loaded through Assets with more than one alias is now registered under all of them (#323), so sound.remove(alias) removes every alias that points at the same Sound.
5.x is on the latest-5.x npm dist-tag: npm install @pixi/sound@latest-5.x.