From 53d557c2db9e51c98696840e19aced94687be0ea Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Thu, 22 Mar 2018 11:02:14 +0100 Subject: [PATCH] [d3d11] Implement D3D11_MAP_FLAG_DO_NOT_WAIT Improves framerate in Dishonored 2 by up to 50%. --- src/d3d11/d3d11_context_imm.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/d3d11/d3d11_context_imm.cpp b/src/d3d11/d3d11_context_imm.cpp index ca04616e..492da900 100644 --- a/src/d3d11/d3d11_context_imm.cpp +++ b/src/d3d11/d3d11_context_imm.cpp @@ -347,6 +347,9 @@ namespace dxvk { SynchronizeCsThread(); if (Resource->isInUse()) { + if (MapFlags & D3D11_MAP_FLAG_DO_NOT_WAIT) + return false; + // TODO implement properly in DxvkDevice while (Resource->isInUse()) std::this_thread::yield();