From afaa3b5a3017112fb0dc10aaa3ed7d3d7d75a4cc Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Sat, 10 Mar 2018 14:41:06 +0100 Subject: [PATCH] [d3d11] Fix minor code inconsistencies --- src/d3d11/d3d11_context.cpp | 1 - src/d3d11/d3d11_context_def.cpp | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/d3d11/d3d11_context.cpp b/src/d3d11/d3d11_context.cpp index 894b63c4..08bc78c4 100644 --- a/src/d3d11/d3d11_context.cpp +++ b/src/d3d11/d3d11_context.cpp @@ -628,7 +628,6 @@ namespace dxvk { clearRect.baseArrayLayer = 0; clearRect.layerCount = view->info().numLayers; - // FIXME Is this correct? Docs don't say anything if (m_parent->GetFeatureLevel() < D3D_FEATURE_LEVEL_10_0) clearRect.layerCount = 1; diff --git a/src/d3d11/d3d11_context_def.cpp b/src/d3d11/d3d11_context_def.cpp index 2b616836..09206328 100644 --- a/src/d3d11/d3d11_context_def.cpp +++ b/src/d3d11/d3d11_context_def.cpp @@ -47,10 +47,10 @@ namespace dxvk { *ppCommandList = m_commandList.ref(); m_commandList = CreateCommandList(); - if (!RestoreDeferredContextState) - ClearState(); - else + if (RestoreDeferredContextState) RestoreState(); + else + ClearState(); return S_OK; }