tri/cube: Handle window resizes (from WSI or XCB).

If either vkAcquireNextImageKHR() or vkQueuePresentKHR() return
VK_ERROR_OUT_OF_DATE, a new demo_resize() function is called, that replaces the
current state, command buffers, swapchain, etc, with new ones that reflect the
new size of the window.  As part of this, the app picks up the window size from
vkGetSurfacePropertiesKHR().

The same occurs if the application receives an XCB_CONFIGURE_NOTIFY event, with
a changed window size.
2 files changed