Skia Viewer - FPS Locked to 60?

360 views
Skip to first unread message

Ellison Zhang

unread,
Dec 20, 2021, 9:26:22 PM12/20/21
to skia-discuss
Hi skia folks,

We are working around Skia Viewer in order to get a good insight of Skia. We built skia on windows 10 with the vulkan backend enabled. 
As it is shown is figures, we found the FPS of all the Viewer examples using Vulkan backend are locked to 60. This issue may also happened to OpenGl backend in some devices. Any mechanism about this? why the FPS of viewer examples are sometimes locked to 60?

GM_addarc_meas_Vulkan.PNG
              Fig 1. Vulkan backend locked to 60 fps
GM_aaxfer_Vulkan.PNG
                      Fig 2. Vulkan backend locked to 60 fps
GM_aaxfer_opengl.PNG
                          Fig 3. OpenGL backend normal FPS

Brian Osman

unread,
Dec 21, 2021, 9:27:43 AM12/21/21
to skia-d...@googlegroups.com
Viewer attempts to disable vsync (and make it configurable). There is a parameter fDisableVsync that can be toggled by pressing 'v'. Unfortunately, there are many other factors at play that can make it difficult or impossible to disable (or enable) vsync, depending on OS, GPU, etc... In some cases, the display driver will have overrides (via the driver's control panel) that will ignore any setting from the application. If you search the code for fDisableVsync, you can see where the different window-context classes use that (Vulkan does change the present mode). So it's possible that something else is locking the framerate (like a display driver setting).

--
You received this message because you are subscribed to the Google Groups "skia-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to skia-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/skia-discuss/690a7858-81f8-4aec-a293-b2a0688015bbn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages