diff options
Diffstat (limited to 'src/vk/graphics_pipeline_3d.cpp')
-rw-r--r-- | src/vk/graphics_pipeline_3d.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/vk/graphics_pipeline_3d.cpp b/src/vk/graphics_pipeline_3d.cpp index 43ab734..d98a27d 100644 --- a/src/vk/graphics_pipeline_3d.cpp +++ b/src/vk/graphics_pipeline_3d.cpp @@ -277,6 +277,10 @@ GraphicsPipeline3D::draw( vkCmdSetScissor(draw_command_buffer, 0, 1, &vk_scissor); } + vkCmdBindPipeline( + draw_command_buffer, VK_PIPELINE_BIND_POINT_GRAPHICS, + this->graphic_pipeline); + // Draw models for(auto& [static_mesh, instances]: cg_core.vk_renderer->static_models_to_draw[current_frame]) @@ -284,9 +288,6 @@ GraphicsPipeline3D::draw( VkBuffer vertex_buffers[]{static_mesh->vertex_buffer->buffer}; VkDeviceSize offsets[]{0}; - vkCmdBindPipeline( - draw_command_buffer, VK_PIPELINE_BIND_POINT_GRAPHICS, - this->graphic_pipeline); vkCmdBindVertexBuffers( draw_command_buffer, 0, 1, vertex_buffers, offsets); vkCmdBindIndexBuffer( |