fix(linux): use OnDemand GPU policy for AMD/Intel Mesa

WebKitGTK 6.0 removed WEBKIT_HARDWARE_ACCELERATION_POLICY_ON_DEMAND, so Wails maps OnDemand to ALWAYS. Never (the old Nvidia/X11 blank-window workaround) forces CPU raster on the GTK4/WebKit 6 stack. All target machines are AMD or Intel, where the Nvidia DMABUF workaround is unnecessary, so let the GPU handle scrolling/compositing.
This commit is contained in:
John O'Keefe
2026-09-15 21:35:33 -04:00
parent 01299994b4
commit 1d4fa38b8e
+6 -1
View File
@@ -47,7 +47,12 @@ func main() {
Linux: application.LinuxWindow{
Icon: []byte("./build/AniTrack.png"),
WindowIsTranslucent: false,
WebviewGpuPolicy: application.WebviewGpuPolicyNever,
// OnDemand: GPU for scrolling/compositing on AMD/Intel Mesa,
// software fallback otherwise. Never (the old Nvidia/X11
// blank-window workaround) forces CPU raster on GTK4/WebKit 6
// and makes scrolling janky. All target machines here are
// AMD or Intel, so the Nvidia DMABUF workaround is not needed.
WebviewGpuPolicy: application.WebviewGpuPolicyOnDemand,
},
})