descriptor heap rewrite
This commit is contained in:
parent
b4bd0c03c5
commit
f8e142fb06
31 changed files with 429 additions and 1017 deletions
|
|
@ -51,9 +51,6 @@ import :Types;
|
|||
import :Rendertarget;
|
||||
import :Transform2D;
|
||||
import Crafter.Event;
|
||||
#ifdef CRAFTER_GRAPHICS_RENDERER_VULKAN
|
||||
import :PipelineRTVulkan;
|
||||
#endif
|
||||
|
||||
export namespace Crafter {
|
||||
#ifdef CRAFTER_GRAPHICS_RENDERER_VULKAN
|
||||
|
|
@ -63,6 +60,8 @@ export namespace Crafter {
|
|||
// Command buffer submission and execution
|
||||
VkSemaphore renderComplete;
|
||||
};
|
||||
struct PipelineRTVulkan;
|
||||
struct DescriptorHeapVulkan;
|
||||
#endif
|
||||
|
||||
struct MouseElement;
|
||||
|
|
@ -178,17 +177,6 @@ export namespace Crafter {
|
|||
#endif
|
||||
|
||||
#ifdef CRAFTER_GRAPHICS_RENDERER_VULKAN
|
||||
std::vector<VkDescriptorSet> descriptorsRt;
|
||||
template <typename Pipeline>
|
||||
void SetPipelineRT() {
|
||||
rtPipeline = Pipeline::pipeline;
|
||||
rtPipelineLayout = Pipeline::pipelineLayout;
|
||||
raygenRegion = Pipeline::raygenRegion;
|
||||
missRegion = Pipeline::missRegion;
|
||||
hitRegion = Pipeline::hitRegion;
|
||||
callableRegion = Pipeline::callableRegion;
|
||||
}
|
||||
void SetPipelineRT(PipelineRTVulkan& pipeline);
|
||||
VkCommandBuffer StartInit();
|
||||
void FinishInit();
|
||||
VkCommandBuffer GetCmd();
|
||||
|
|
@ -200,19 +188,15 @@ export namespace Crafter {
|
|||
VkFormat colorFormat;
|
||||
VkColorSpaceKHR colorSpace;
|
||||
VkImage images[numFrames];
|
||||
VkImageView imageViews[numFrames];
|
||||
VkImageViewCreateInfo imageViews[numFrames];
|
||||
std::thread thread;
|
||||
VkCommandBuffer drawCmdBuffers[numFrames];
|
||||
VkSubmitInfo submitInfo;
|
||||
Semaphores semaphores;
|
||||
std::uint32_t currentBuffer = 0;
|
||||
VkPipelineStageFlags submitPipelineStages = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT;
|
||||
VkPipeline rtPipeline;
|
||||
VkPipelineLayout rtPipelineLayout;
|
||||
VkStridedDeviceAddressRegionKHR raygenRegion;
|
||||
VkStridedDeviceAddressRegionKHR missRegion;
|
||||
VkStridedDeviceAddressRegionKHR hitRegion;
|
||||
VkStridedDeviceAddressRegionKHR callableRegion;
|
||||
PipelineRTVulkan* pipeline;
|
||||
DescriptorHeapVulkan* descriptorHeap;
|
||||
#endif
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue