Fix queue passed to vkQueuePresent

We do not test actively test setups where a separate graphics and
present queue is used because there is no combined queue at all. (it
won't be tested because we neither want to nor have the possibility to
do so)

However, QVulkanWindow (unlike, say, QRhi's Vulkan backend) attempts
to support this. It turns out the argument passed to vkQueuePresent is
wrong: the present is to be submitted to the present queue. So fix
this up.

Pick-to: 6.3 6.2 5.15
Fixes: QTBUG-73470
Change-Id: Ic9b589aba52e3326637216b98a074e27fdc3e3b9
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
This commit is contained in:
Laszlo Agocs 2022-01-19 19:10:38 +01:00
parent 9a9b253b68
commit f0057f0269

View File

@ -2021,7 +2021,7 @@ void QVulkanWindowPrivate::endFrame()
// order to circumvent driver frame callbacks
inst->presentAboutToBeQueued(q);
err = vkQueuePresentKHR(gfxQueue, &presInfo);
err = vkQueuePresentKHR(presQueue, &presInfo);
if (err != VK_SUCCESS) {
if (err == VK_ERROR_OUT_OF_DATE_KHR) {
recreateSwapChain();