Skip to content
Snippets Groups Projects
Commit dd240099 authored by Sascha Willems's avatar Sascha Willems
Browse files

Remove unused push constants

Fies #901
parent 3b7098d6
No related branches found
No related tags found
No related merge requests found
......@@ -3,7 +3,7 @@
*
* Updated compute shader by Lukas Bergdoll (https://github.com/Voultapher)
*
* Copyright (C) 2016 by Sascha Willems - www.saschawillems.de
* Copyright (C) 2016-2021 by Sascha Willems - www.saschawillems.de
*
* This code is licensed under the MIT license (MIT) (http://opensource.org/licenses/MIT)
*/
......@@ -168,15 +168,6 @@ public:
vkCmdBindPipeline(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_GRAPHICS, graphics.pipeline);
vkCmdBindDescriptorSets(drawCmdBuffers[i], VK_PIPELINE_BIND_POINT_GRAPHICS, graphics.pipelineLayout, 0, 1, &graphics.descriptorSet, 0, NULL);
glm::vec2 screendim = glm::vec2((float)width, (float)height);
vkCmdPushConstants(
drawCmdBuffers[i],
graphics.pipelineLayout,
VK_SHADER_STAGE_VERTEX_BIT,
0,
sizeof(glm::vec2),
&screendim);
VkDeviceSize offsets[1] = { 0 };
vkCmdBindVertexBuffers(drawCmdBuffers[i], VERTEX_BUFFER_BIND_ID, 1, &compute.storageBuffer.buffer, offsets);
vkCmdDraw(drawCmdBuffers[i], PARTICLE_COUNT, 1, 0, 0);
......@@ -432,15 +423,6 @@ public:
&graphics.descriptorSetLayout,
1);
VkPushConstantRange pushConstantRange =
vks::initializers::pushConstantRange(
VK_SHADER_STAGE_VERTEX_BIT,
sizeof(glm::vec2),
0);
pipelineLayoutCreateInfo.pushConstantRangeCount = 1;
pipelineLayoutCreateInfo.pPushConstantRanges = &pushConstantRange;
VK_CHECK_RESULT(vkCreatePipelineLayout(device, &pipelineLayoutCreateInfo, nullptr, &graphics.pipelineLayout));
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment