summaryrefslogtreecommitdiffstats
path: root/Graphics/GraphicsEngineD3DBase
diff options
context:
space:
mode:
authorEgor Yusov <egor.yusov@gmail.com>2018-04-01 20:03:19 +0000
committerEgor Yusov <egor.yusov@gmail.com>2018-04-01 20:03:19 +0000
commit18d59732724500f094510cece80afd83e3256282 (patch)
treef1fb4de1f2decb833031349ed642b101830a056f /Graphics/GraphicsEngineD3DBase
parentUpdated readme with current progress (diff)
downloadDiligentCore-18d59732724500f094510cece80afd83e3256282.tar.gz
DiligentCore-18d59732724500f094510cece80afd83e3256282.zip
Added comment
Diffstat (limited to 'Graphics/GraphicsEngineD3DBase')
-rw-r--r--Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.h b/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.h
index 743c9793..9f69d55b 100644
--- a/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.h
+++ b/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.h
@@ -49,9 +49,10 @@ namespace Diligent
~SwapChainD3DBase()
{
- // Swap chain must be in windowed mode when terminating the app
if (m_pSwapChain)
{
+ // Swap chain must be in windowed mode when it is destroyed
+ // https://msdn.microsoft.com/en-us/library/windows/desktop/bb205075(v=vs.85).aspx#Destroying
BOOL IsFullScreen = FALSE;
m_pSwapChain->GetFullscreenState(&IsFullScreen, nullptr);
if (IsFullScreen)
@@ -173,6 +174,7 @@ namespace Diligent
{
// If we are already in fullscreen mode, we need to switch to windowed mode first,
// because a swap chain must be in windowed mode when it is released.
+ // https://msdn.microsoft.com/en-us/library/windows/desktop/bb205075(v=vs.85).aspx#Destroying
if (m_FSDesc.Fullscreen)
m_pSwapChain->SetFullscreenState(FALSE, nullptr);
m_FSDesc.Fullscreen = True;