From 81400ebf6c77c09ea12bbc532ea5658b3c09fc87 Mon Sep 17 00:00:00 2001 From: Egor Yusov Date: Sat, 31 Mar 2018 22:39:38 -0700 Subject: Fixed issue with d3d11 swap chain faling to resize due to command lists not being released --- Projects/Asteroids/src/asteroids_DE.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Projects') diff --git a/Projects/Asteroids/src/asteroids_DE.cpp b/Projects/Asteroids/src/asteroids_DE.cpp index 4d7501b..40d9db2 100644 --- a/Projects/Asteroids/src/asteroids_DE.cpp +++ b/Projects/Asteroids/src/asteroids_DE.cpp @@ -769,6 +769,10 @@ void Asteroids::Render(float frameTime, const OrbitCamera& camera, const Setting for(auto &cmdList : mCmdLists) { mDeviceCtxt->ExecuteCommandList(cmdList); + // Release command lists now to release all outstanding references + // In d3d11 mode, command lists hold references to the swap chain's back buffer + // that cause swap chain resize to fail + cmdList.Release(); } } -- cgit v1.2.3