Fix potential rare issues with material shader constants containing invalid data

This commit is contained in:
2023-02-18 18:25:40 +01:00
parent 5911d098d1
commit e644b65289
@@ -231,6 +231,7 @@ bool MaterialShader::Load(MemoryReadStream& shaderCacheStream, const MaterialInf
_cb = nullptr;
}
_cbData.Resize(cbSize, false);
Platform::MemoryClear(_cbData.Get(), cbSize);
}
// Initialize the material based on type (create pipeline states and setup)