feat: Modify the next frame delay method by changing setTimeout to re…#857
feat: Modify the next frame delay method by changing setTimeout to re…#857Planck-Ho wants to merge 1 commit intolichtblick-suite:developfrom
Conversation
|
Hi @Planck-Ho |
|
Hey @Planck-Ho first of all thank you for your contribution, while testing this change I noticed that this change affected by a considerable amount performance on some use cases. I think the do while loop logic is waiting multiple times per frame causing this issue. I dont know if it will fix it, but you can try to remove the do while condition or use a single Also rebase your branch with develop and fix conflicts. Cheers, |
Perhaps under high refresh rate displays, |
|
Thanks for the explanation your reasoning around However, after testing this internally we found that certain use cases, as I stated, take a performance hit with this change. The do-while loop iterating multiple times per tick ends up introducing overhead that outweighs the benefits in our current setup, so unfortunately we can't merge this right now. We'll keep the idea in mind as something to revisit down the line. Thanks again for the contribution! Cheers, |
…questAnimationFrame #856
Modify the next frame delay method by changing setTimeout to requestAnimationFrame
Description
Checklist