Skip to content

Commit

Permalink
Set firstInstance to zero
Browse files Browse the repository at this point in the history
Fixes #1159
  • Loading branch information
SaschaWillems committed Oct 10, 2024
1 parent add736f commit 128b096
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions examples/triangle/triangle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -979,7 +979,7 @@ class VulkanExample : public VulkanExampleBase
scissor.offset.x = 0;
scissor.offset.y = 0;
vkCmdSetScissor(commandBuffer, 0, 1, &scissor);
// Bind descriptor set for the currrent frame's uniform buffer, so the shader uses the data from that buffer for this draw
// Bind descriptor set for the current frame's uniform buffer, so the shader uses the data from that buffer for this draw
vkCmdBindDescriptorSets(commandBuffer, VK_PIPELINE_BIND_POINT_GRAPHICS, pipelineLayout, 0, 1, &uniformBuffers[currentFrame].descriptorSet, 0, nullptr);
// Bind the rendering pipeline
// The pipeline (state object) contains all states of the rendering pipeline, binding it will set all the states specified at pipeline creation time
Expand All @@ -990,7 +990,7 @@ class VulkanExample : public VulkanExampleBase
// Bind triangle index buffer
vkCmdBindIndexBuffer(commandBuffer, indices.buffer, 0, VK_INDEX_TYPE_UINT32);
// Draw indexed triangle
vkCmdDrawIndexed(commandBuffer, indices.count, 1, 0, 0, 1);
vkCmdDrawIndexed(commandBuffer, indices.count, 1, 0, 0, 0);
vkCmdEndRenderPass(commandBuffer);
// Ending the render pass will add an implicit barrier transitioning the frame buffer color attachment to
// VK_IMAGE_LAYOUT_PRESENT_SRC_KHR for presenting it to the windowing system
Expand Down
4 changes: 2 additions & 2 deletions examples/trianglevulkan13/trianglevulkan13.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -740,7 +740,7 @@ class VulkanExample : public VulkanExampleBase
// Update dynamic scissor state
VkRect2D scissor{ 0, 0, width, height };
vkCmdSetScissor(commandBuffer, 0, 1, &scissor);
// Bind descriptor set for the currrent frame's uniform buffer, so the shader uses the data from that buffer for this draw
// Bind descriptor set for the current frame's uniform buffer, so the shader uses the data from that buffer for this draw
vkCmdBindDescriptorSets(commandBuffer, VK_PIPELINE_BIND_POINT_GRAPHICS, pipelineLayout, 0, 1, &uniformBuffers[currentFrame].descriptorSet, 0, nullptr);
// The pipeline (state object) contains all states of the rendering pipeline, binding it will set all the states specified at pipeline creation time
vkCmdBindPipeline(commandBuffer, VK_PIPELINE_BIND_POINT_GRAPHICS, pipeline);
Expand All @@ -750,7 +750,7 @@ class VulkanExample : public VulkanExampleBase
// Bind triangle index buffer
vkCmdBindIndexBuffer(commandBuffer, indexBuffer.handle, 0, VK_INDEX_TYPE_UINT32);
// Draw indexed triangle
vkCmdDrawIndexed(commandBuffer, indexCount, 1, 0, 0, 1);
vkCmdDrawIndexed(commandBuffer, indexCount, 1, 0, 0, 0);
// Finish the current dynamic rendering section
vkCmdEndRendering(commandBuffer);

Expand Down

0 comments on commit 128b096

Please sign in to comment.