Skip to content

Commit ea275f6

Browse files
committed
Fix code snippet that was not updated as part of #255
1 parent 17dec07 commit ea275f6

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

en/04_Vertex_buffers/01_Vertex_buffer_creation.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -295,16 +295,16 @@ Flushing memory ranges or using a coherent memory heap means that the driver wil
295295
## Binding the vertex buffer
296296

297297
All that remains now is binding the vertex buffer during rendering operations.
298-
We're going to extend the `createCommandBuffers` function to do that.
298+
We're going to extend the `recordCommandBuffer` function to do that.
299299

300300
```c++
301-
vkCmdBindPipeline(commandBuffers[i], VK_PIPELINE_BIND_POINT_GRAPHICS, graphicsPipeline);
301+
vkCmdBindPipeline(commandBuffer, VK_PIPELINE_BIND_POINT_GRAPHICS, graphicsPipeline);
302302

303303
VkBuffer vertexBuffers[] = {vertexBuffer};
304304
VkDeviceSize offsets[] = {0};
305-
vkCmdBindVertexBuffers(commandBuffers[i], 0, 1, vertexBuffers, offsets);
305+
vkCmdBindVertexBuffers(commandBuffer, 0, 1, vertexBuffers, offsets);
306306

307-
vkCmdDraw(commandBuffers[i], static_cast<uint32_t>(vertices.size()), 1, 0, 0);
307+
vkCmdDraw(commandBuffer, static_cast<uint32_t>(vertices.size()), 1, 0, 0);
308308
```
309309
310310
The `vkCmdBindVertexBuffers` function is used to bind vertex buffers to

0 commit comments

Comments
 (0)