mirror of https://github.com/mpv-player/mpv
b8bb5329a5
By design, some vulkan implementations block until vsync during vkAcquireNextImageKHR. Since mpv only considers the time that `swap_buffers` spent blocking as constituting part of the vsync, we can help it out a bit by pre-emptively calling this function here in order to improve the accuracy of vsync jitter measurements on vulkan. (If it fails, we just ignore the error and have the user call it a second time later - maybe it will work then) On my system this drops vsync-jitter from ~0.030 to ~0.007, an accuracy of +/- 100μs. (Which *might* have something to do with the fact that this is the polling interval for command polling) |
||
---|---|---|
.. | ||
common.h | ||
context.c | ||
context.h | ||
context_wayland.c | ||
context_win.c | ||
context_xlib.c | ||
formats.c | ||
formats.h | ||
malloc.c | ||
malloc.h | ||
ra_vk.c | ||
ra_vk.h | ||
spirv_nvidia.c | ||
utils.c | ||
utils.h |