Closed alana314 closed 7 months ago
I may be wrong about this being a memory leak, I set the tab in chrome's performance settings to never sleep and it's working better, though it still does glitch occasionally after an hour or two.
I believe I've tracked this down to a chrome web audio memory leak bug with linearRampToValueAtTime, which Howler uses. Running it in firefox works fine. https://bugs.chromium.org/p/chromium/issues/detail?id=166853
The Problem
I have several wavs on loop playing with howler and using fades to crossfade between them. Howler does a good job of restarting the loops seamlessly and at the exact same time. I was using as many as 32 but eventually when running for an hour or two, the audio got choppy and distorted. I lowered it to 12 loops but it still happens after 2 hours. A refresh of the webpage fixes it.
Reproducible Example
No response
Reproduction Steps
Start loops with:
fade them individually or together with
sound.fade(sound.volume(), 1, transitionLength * 1000)
The google chrome tab only seems to use 231MB, but starts stuttering after 2 hours. Is there a memory leak with loops? I'm also using websockets to trigger the fades.Possible Solution
No response
Context
I'm using howler to provide background music for an installation with different states throughout the day.
Howler.js Version
v2.2.4
Affected Browser(s)/Versiuon(s)
Chrome 118.0