For example, when you do horizontal animation, which one is faster?
Speed = I would like to know which FPS is better.
For example, for devices with poor specs,
From the question of which FPS is more expensive
It was a question.
Both CSS transition and requestAnimationFrame()
will update the drawing according to the hardware refresh rate.Therefore, the FPS will be the same regardless of whether the CPU is fast enough.
requestAnimationFrame()
is more likely to cause the FPS to drop when the CPU is slow or animation or other processes are heavy.There is always an overhead to bridge the browser's native code with the JavaScript world.
© 2024 OneMinuteCode. All rights reserved.