Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions attachments/15_hello_triangle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,7 @@ class HelloTriangleApplication {
glfwPollEvents();
drawFrame();
}

device.waitIdle();
device.waitIdle(); // wait for device to finish operations before destroying resources
}

void cleanup() {
Expand Down Expand Up @@ -456,7 +455,8 @@ class HelloTriangleApplication {
}

void drawFrame() {
queue.waitIdle();
queue.waitIdle(); // NOTE: for simplicity, wait for the queue to be idle before starting the frame
// In the next chapter you see how to use multiple frames in flight and fences to sync

auto [result, imageIndex] = swapChain.acquireNextImage( UINT64_MAX, *presentCompleteSemaphore, nullptr );
recordCommandBuffer(imageIndex);
Expand Down
Loading