We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c6df655 commit 318dffcCopy full SHA for 318dffc
en/03_Drawing_a_triangle/04_Swap_chain_recreation.adoc
@@ -57,12 +57,12 @@ We'll move the cleanup code of all objects that are recreated as part of a swap
57
[,c++]
58
----
59
void cleanupSwapChain() {
60
- for (size_t i = 0; i < swapChainFramebuffers.size(); i++) {
61
- vkDestroyFramebuffer(device, swapChainFramebuffers[i], nullptr);
+ for (auto framebuffer : swapChainFramebuffers) {
+ vvkDestroyFramebuffer(device, framebuffer, nullptr);
62
}
63
64
- for (size_t i = 0; i < swapChainImageViews.size(); i++) {
65
- vkDestroyImageView(device, swapChainImageViews[i], nullptr);
+ for (auto imageView : swapChainImageViews) {
+ vkDestroyImageView(device, imageView, nullptr);
66
67
68
vkDestroySwapchainKHR(device, swapChain, nullptr);
0 commit comments