summaryrefslogtreecommitdiffstats
path: root/Graphics/GraphicsEngineVulkan
diff options
context:
space:
mode:
Diffstat (limited to 'Graphics/GraphicsEngineVulkan')
-rw-r--r--Graphics/GraphicsEngineVulkan/src/PipelineStateVkImpl.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/Graphics/GraphicsEngineVulkan/src/PipelineStateVkImpl.cpp b/Graphics/GraphicsEngineVulkan/src/PipelineStateVkImpl.cpp
index 443076df..ec5ff6b3 100644
--- a/Graphics/GraphicsEngineVulkan/src/PipelineStateVkImpl.cpp
+++ b/Graphics/GraphicsEngineVulkan/src/PipelineStateVkImpl.cpp
@@ -453,9 +453,13 @@ PipelineStateVkImpl::~PipelineStateVkImpl()
}
auto& RawAllocator = GetRawAllocator();
- for (Uint32 s=0; s < m_NumShaders; ++s)
+ for (Uint32 s=0; s < m_NumShaders*2; ++s)
{
m_ShaderResourceLayouts[s].~ShaderResourceLayoutVk();
+ }
+
+ for (Uint32 s=0; s < m_NumShaders; ++s)
+ {
m_StaticResCaches[s].~ShaderResourceCacheVk();
m_StaticVarsMgrs[s].Destroy(GetRawAllocator());
m_StaticVarsMgrs[s].~ShaderVariableManagerVk();