mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2026-04-20 02:40:27 +00:00
Instead of copying the Bitmap that wraps the IOSurface, we can just present the IOSurface directly. This significantly reduces CPU usage in the UI process, particularly at high refresh rates such as 120Hz where it would saturate a full CPU core. This is done by using CAMetalLayer and blitting the IOSurface to the next drawable buffer, which handles triple buffering, locking the IOSurface and vsync automatically. This also allows the Metal HUD to work, but the only accurate stat is the frame intervals/FPS because it's in the UI layer, not WebContent. However, that's still useful to detect frame drops. |
||
|---|---|---|
| .. | ||
| Autocomplete.h | ||
| Autocomplete.mm | ||
| Event.h | ||
| Event.mm | ||
| InfoBar.h | ||
| InfoBar.mm | ||
| LadybirdWebView.h | ||
| LadybirdWebView.mm | ||
| LadybirdWebViewBridge.cpp | ||
| LadybirdWebViewBridge.h | ||
| LadybirdWebViewWindow.h | ||
| LadybirdWebViewWindow.mm | ||
| Menu.h | ||
| Menu.mm | ||
| Palette.h | ||
| Palette.mm | ||
| SearchPanel.h | ||
| SearchPanel.mm | ||
| Tab.h | ||
| Tab.mm | ||
| TabController.h | ||
| TabController.mm | ||