Created
May 16, 2023 16:51
-
-
Save sjhalayka/bcf49660d2379532e398a4fa3e3b07fd to your computer and use it in GitHub Desktop.
render function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
virtual void render() | |
{ | |
if (!prepared) | |
return; | |
VulkanExampleBase::prepareFrame(); | |
submitInfo.commandBufferCount = 1; | |
submitInfo.pCommandBuffers = &drawCmdBuffers[currentBuffer]; | |
VK_CHECK_RESULT(vkQueueSubmit(queue, 1, &submitInfo, fence)); | |
VulkanExampleBase::submitFrame(); | |
vkWaitForFences(device, 1, &fence, VK_TRUE, UINT64_MAX); | |
if(do_screenshot) | |
{ | |
screenshot(width * 6, height * 6, "v_rt_reflect.png"); | |
do_screenshot = false; | |
} | |
vkResetFences(device, 1, &fence); | |
if (!paused || camera.updated) | |
updateUniformBuffers(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment