improved Swapchain&SwapchainRenderTarget

This commit is contained in:
2021-12-15 20:46:33 +08:00
parent 14b9369739
commit ee9be8a4a2
8 changed files with 64 additions and 81 deletions

View File

@@ -13,23 +13,14 @@ public:
VkExtent2D extent;
VkQueue graphics_queue =VK_NULL_HANDLE;
VkSwapchainKHR swap_chain =VK_NULL_HANDLE;
uint32_t swap_chain_count=0;
uint32_t color_count=0;
ObjectList<Texture2D> sc_color;
Texture2D ** sc_color =nullptr;
Texture2D * sc_depth =nullptr;
public:
VkSwapchainKHR GetSwapchain () {return swap_chain;}
const VkExtent2D & GetExtent ()const {return extent;}
const uint32_t GetImageCount ()const {return sc_color.GetCount();}
Texture2D ** GetColorTextures () {return sc_color.GetData();}
Texture2D * GetColorTexture (int index) {return sc_color[index];}
Texture2D * GetDepthTexture () {return sc_depth;}
Framebuffer ** render_frame =nullptr;
public: