Open bramus opened 10 months ago
For comparison, here’s a performance profile measured in Safari to show the difference.
With FPS Meter | Without FPS Meter |
---|---|
(Note that the 9fps in the one screenshot isn’t representative. It’s the ongoing profiling that is slowing things down. When not profiling, the reported number is around 49fps on my machine)
The FPS Meter widget is updated via rAF. While not a problem in itself, this is causing issues for WAAPI/CSS animations in some browsers (see https://github.com/slaylines/canvas-engines-comparison/issues/69 for these tests).
In Blink (Chromium), the presence of a rAF will cause the animations – which already happened on the compositor – to also happen on the main thread because you could query for style values inside the rAF. Because of this, WAAPI/CSS animations perform worse when the FPS Meter is present.
See https://bramus.github.io/canvas-engines-comparison/dom-waapi.html for an implementation that allows disabling the FPS Meter widget.