[Chore] (MG_Backend/DirectVulkan): manage active renderpass inside RenderPassManager static functions

This commit is contained in:
2026-03-01 23:02:54 +08:00
parent 6f8c76f06c
commit 16426db244
3 changed files with 18 additions and 4 deletions
@@ -71,6 +71,7 @@ namespace MobileGL::MG_Backend::DirectVulkan {
RenderPassEntry& GetOrCreateRenderPass(const MG_State::GLState::FramebufferObject& fbo);
static Bool BeginRenderPass(VkCommandBuffer commandBuffer, RenderPassEntry& renderPassEntry);
static Bool EndRenderPass(VkCommandBuffer commandBuffer);
static RenderPassEntry* GetActiveRenderPass();
private:
VkDevice m_device = VK_NULL_HANDLE;
const VulkanRendererConfig& m_config;
@@ -78,5 +79,6 @@ namespace MobileGL::MG_Backend::DirectVulkan {
VkTextureManager& m_textureManager;
UnorderedMap<Uint64, RenderPassEntry> m_renderPasses;
static inline XXH64_state_t* m_hashState = XXH64_createState();
static inline RenderPassEntry* s_activeRenderPass = nullptr;
};
} // namespace MobileGL::MG_Backend::DirectVulkan