Search Issue Tracker
Fixed in 2021.1.X
Fixed in 2019.4.X, 2020.3.X
[WebGL] AudioSource.Update CPU usage increases overtime when playing AudioSources on Chromium browsers
1. Open the user's attached project
2. Make a WebGL Development Build with Autoconnect Profiler enabled and run it
3. Inspect the CPU usage of "AudioSource.Update" method
4. Let the build run in browser for ~5-10mins (it can be muted)
5. Inspect the CPU usage of "AudioSource.Update" method again
Expected result: CPU usage remains relatively the same
Actual result: CPU usage increases several times (from ~0.3ms to ~3ms and more)
Reproducible with: 2018.4.26f1, 2019.4.9f1, 2020.1.4f1, 2020.2.0a21
Reproducible with Chrome (84.0.4147.135), Edge (84.0.522.63)
Does not reproduce on Firefox (79.0)
1. Stopping and then resuming playing audio tracks do not decrease CPU usage
2. In Chrome's profiler, "_JS_Sound_SetPosition" function shows up a lot
3. On 2020.2.0a21, audio tracks cannot be heard, and Audio Voices count increases rapidly in the Profiler. After a few seconds "Autoconnected Player Ran out of virtual channels. Audio clip "pistol - Copy" will not be played." warnings start to be thrown repeatedly
Nov 09, 2021 15:13
I have a looping music track in a Unity 2019.4 WebGL project, and it starts to steadily increase noise and static after 2 minutes or so, until it becomes a horrible mess.
Aug 07, 2021 15:49
Is there an ETA for this fix coming to 2019.4.X? The latest Chromium update has made this issue far more prevalent and live titles (Betrayal IO, for example) are unplayable after an hour due to this bug.
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
- Native Plugins are not found when they are depending on each other
- Errors are thrown after redoing Nested Prefab Variant creation
- Documentation Link does not work when the "VFX Condition" question mark button is clicked
- Documentation Link does not work when the "Spawn State" question mark button is clicked
- Darker lighting in Build when disabling SSAO at runtime
Resolution Note (fix version 2021.1):
Root cause turned out to be a performance bug in Chrome, but there is a local workaround we can apply. For more information, check out https://bugs.chromium.org/p/chromium/issues/detail?id=1133233.
Fixed in 2021.1.0a1
Resolution Note (fix version 2019.4):
Fixed in 2019.4.35f1