Has anyone encountered a similar issue?
That user experience and ways of handling it greatly depend on the use case, and your custom code.
- For animations you usually pass
dttoupdatemethod to update the mixer. Passing a large time delta can result in things going crazy. requestAnimationFrameis called only when your browser and tab are open. Switching tabs will temporarily disable therequestAnimationFramefrom being executed. Make sure you’re not handling any important, time-dependent logic there - usesetTimeout / setIntervalinstead, as it’ll keep executing even when the tab is not in focus (it slows down when you minimise the browser, but it won’t stop. So if you update mixer insetTimeout / setIntervalloop, deltas will not get too big.)- Alternatively, you can just pause the entire logic and rendering when tab / browser is minised - visibilitychange event on document should help with that.
1 Like