Changeset 58453c3 in opengl-game for sdl-game.cpp


Ignore:
Timestamp:
May 20, 2021, 3:50:12 PM (3 years ago)
Author:
Dmitry Portnoy <dportnoy@…>
Branches:
feature/imgui-sdl
Children:
567fa88
Parents:
c163d81
git-author:
Dmitry Portnoy <dportnoy@…> (05/20/21 15:48:15)
git-committer:
Dmitry Portnoy <dportnoy@…> (05/20/21 15:50:12)
Message:

Remove the swapChainImages parameter from the GraphicsPipeline_Vulkan constructor and modify createDescriptorPool(), createDescriptorSets(), and updateDescriptorInfo() to accept a size paramter instead of accepting a vector of swap chain images and getting the size from that

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sdl-game.cpp

    rc163d81 r58453c3  
    169169   modelPipeline.createDescriptorSetLayout();
    170170   modelPipeline.createPipeline("shaders/model-vert.spv", "shaders/model-frag.spv");
    171    modelPipeline.createDescriptorPool(swapChainImages);
    172    modelPipeline.createDescriptorSets(swapChainImages);
     171   modelPipeline.createDescriptorPool(swapChainImages.size());
     172   modelPipeline.createDescriptorSets(swapChainImages.size());
    173173
    174174   currentRenderScreenFn = &VulkanGame::renderMainScreen;
     
    270270   modelPipeline = GraphicsPipeline_Vulkan<ModelVertex>(
    271271      VK_PRIMITIVE_TOPOLOGY_TRIANGLE_LIST, physicalDevice, device, renderPass,
    272       { 0, 0, (int)swapChainExtent.width, (int)swapChainExtent.height }, swapChainImages, 16, 24);
     272      { 0, 0, (int)swapChainExtent.width, (int)swapChainExtent.height }, 16, 24);
    273273
    274274   createBufferSet(objects_modelPipeline.capacity * sizeof(SSBO_ModelObject),
     
    12661266   modelPipeline.updateRenderPass(renderPass);
    12671267   modelPipeline.createPipeline("shaders/model-vert.spv", "shaders/model-frag.spv");
    1268    modelPipeline.createDescriptorPool(swapChainImages);
    1269    modelPipeline.createDescriptorSets(swapChainImages);
     1268   modelPipeline.createDescriptorPool(swapChainImages.size());
     1269   modelPipeline.createDescriptorSets(swapChainImages.size());
    12701270
    12711271   imageIndex = 0;
Note: See TracChangeset for help on using the changeset viewer.