wayland/vulkancontext: Sync surface state before vkQueuePresentKHR
authorJonas Ådahl <jadahl@gmail.com>
Wed, 21 Mar 2018 06:08:13 +0000 (14:08 +0800)
committerJonas Ådahl <jadahl@gmail.com>
Wed, 21 Mar 2018 06:14:32 +0000 (14:14 +0800)
commit7e102f887924a31eaf635823adf884236f434d19
tree0b4a7f6eea390d5d3fdb37ff4d65d58a2494f758
parent1d5d46ff29c7e5c012bf7dd571304cc54fb95bed
wayland/vulkancontext: Sync surface state before vkQueuePresentKHR

A side effect of vkQueuePresentKHR is the Vulkan implementation calling
wl_surface_commit() on the corresponding Wayland surface. Thus, before
this, we must synchronize the surface state (e.g. opaque region, window
geometry, etc) that changed since last time. Prior to this commit this
was done after calling vkQueuePresentKHR(), causing the surface state to
always correspond to the previous buffer state. As of this commit this
is now done before calling vkQueuePresentKHR(), thus before
wl_surface_commit().
gdk/wayland/gdkvulkancontext-wayland.c