Remove duplicate code

Fixes #985
This commit is contained in:
Sascha Willems 2022-08-19 17:50:10 +02:00
parent 5e7b5e6b0b
commit afab3c1624

View file

@ -452,18 +452,12 @@ public:
{ {
VK_CHECK_RESULT(vkBeginCommandBuffer(drawCmdBuffers[i], &cmdBufInfo)); VK_CHECK_RESULT(vkBeginCommandBuffer(drawCmdBuffers[i], &cmdBufInfo));
/*
Dispatch the ray tracing commands
*/
vkCmdBindPipeline(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_RAY_TRACING_KHR, pipeline); vkCmdBindPipeline(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_RAY_TRACING_KHR, pipeline);
vkCmdBindDescriptorSets(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_RAY_TRACING_KHR, pipelineLayout, 0, 1, &descriptorSet, 0, 0); vkCmdBindDescriptorSets(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_RAY_TRACING_KHR, pipelineLayout, 0, 1, &descriptorSet, 0, 0);
/* /*
Dispatch the ray tracing commands Dispatch the ray tracing commands
*/ */
vkCmdBindPipeline(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_RAY_TRACING_KHR, pipeline);
vkCmdBindDescriptorSets(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_RAY_TRACING_KHR, pipelineLayout, 0, 1, &descriptorSet, 0, 0);
VkStridedDeviceAddressRegionKHR emptySbtEntry = {}; VkStridedDeviceAddressRegionKHR emptySbtEntry = {};
vkCmdTraceRaysKHR( vkCmdTraceRaysKHR(
drawCmdBuffers[i], drawCmdBuffers[i],