Skip to content

Commit b0c89c0

Browse files
ek9852ggfan
authored andcommitted
Fix pWaitDstStageMask is null problem
According to specification: If waitSemaphoreCount is not 0, pWaitDstStageMask must be a pointer to an array of waitSemaphoreCount valid combinations of VkPipelineStageFlagBits values Signed-off-by: guanghuafan <gfan@google.com>
1 parent 5dcd954 commit b0c89c0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tutorial05_triangle/app/src/main/jni/VulkanMain.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -808,11 +808,14 @@ bool VulkanDrawFrame(void) {
808808
UINT64_MAX, render.semaphore_,
809809
VK_NULL_HANDLE, &nextIndex));
810810
CALL_VK(vkResetFences(device.device_, 1, &render.fence_));
811+
812+
VkPipelineStageFlags waitStageMask = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT;
811813
VkSubmitInfo submit_info = {
812814
.sType = VK_STRUCTURE_TYPE_SUBMIT_INFO,
813815
.pNext = nullptr,
814816
.waitSemaphoreCount = 1,
815817
.pWaitSemaphores = &render.semaphore_,
818+
.pWaitDstStageMask = &waitStageMask,
816819
.commandBufferCount = 1,
817820
.pCommandBuffers = &render.cmdBuffer_[nextIndex],
818821
.signalSemaphoreCount = 0,

0 commit comments

Comments
 (0)