summaryrefslogtreecommitdiffstats
path: root/Projects/Asteroids/src/asteroids_DE.cpp
diff options
context:
space:
mode:
authorassiduous <assiduous@diligentgraphics.com>2020-11-26 03:22:52 +0000
committerassiduous <assiduous@diligentgraphics.com>2020-11-26 03:22:52 +0000
commite83ccf0539d765193945d2de0d88d9dc55c85aaf (patch)
tree58c3e96730aaf8b281da3a85a371041d1db25af7 /Projects/Asteroids/src/asteroids_DE.cpp
parentUpdated core & tools (diff)
downloadDiligentEngine-e83ccf0539d765193945d2de0d88d9dc55c85aaf.tar.gz
DiligentEngine-e83ccf0539d765193945d2de0d88d9dc55c85aaf.zip
Updated core & samples (fixed premature flushes in VK)
Diffstat (limited to 'Projects/Asteroids/src/asteroids_DE.cpp')
-rw-r--r--Projects/Asteroids/src/asteroids_DE.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/Projects/Asteroids/src/asteroids_DE.cpp b/Projects/Asteroids/src/asteroids_DE.cpp
index 71f7c23..64fdc43 100644
--- a/Projects/Asteroids/src/asteroids_DE.cpp
+++ b/Projects/Asteroids/src/asteroids_DE.cpp
@@ -139,8 +139,8 @@ void Asteroids::InitDevice(HWND hWnd, RENDER_DEVICE_TYPE DevType)
EngineD3D12CreateInfo EngineCI;
EngineCI.NumDeferredContexts = mNumSubsets - 1;
EngineCI.GPUDescriptorHeapDynamicSize[0] = 65536 * 4;
- EngineCI.GPUDescriptorHeapSize[0] = 65536; // For mutable mode
- EngineCI.NumCommandsToFlushCmdList = 1024;
+ EngineCI.GPUDescriptorHeapSize[0] = 65536; // For mutable mode
+ EngineCI.NumCommandsToFlushCmdList = UINT_MAX; // Never flush the context while recording commands
# ifndef _DEBUG
EngineCI.DynamicDescriptorAllocationChunkSize[0] = 8192;
# endif
@@ -160,8 +160,9 @@ void Asteroids::InitDevice(HWND hWnd, RENDER_DEVICE_TYPE DevType)
case RENDER_DEVICE_TYPE_VULKAN:
{
EngineVkCreateInfo EngineCI;
- EngineCI.NumDeferredContexts = mNumSubsets - 1;
- EngineCI.DynamicHeapSize = 64 << 20;
+ EngineCI.NumDeferredContexts = mNumSubsets - 1;
+ EngineCI.DynamicHeapSize = 64 << 20;
+ EngineCI.NumCommandsToFlushCmdBuffer = UINT_MAX; // Never flush the context while recording commands
# if ENGINE_DLL
if (GetEngineFactoryVulkan == nullptr)
GetEngineFactoryVulkan = LoadGraphicsEngineVk();