mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-01-18 02:52:10 +01:00
[d3d11] Disable DO_NOT_WAIT flag by default
Apparently this breaks Elder Scrolls Online as well, so we'll just enable it explicitly for games which benefit from this optimization and disable it by default.
This commit is contained in:
parent
4ed007e9f6
commit
4e84a77896
@ -345,7 +345,7 @@ namespace dxvk {
|
||||
UINT MapFlags) {
|
||||
// Some games (e.g. The Witcher 3) do not work correctly
|
||||
// when a map fails with D3D11_MAP_FLAG_DO_NOT_WAIT set
|
||||
if (m_parent->TestOption(D3D11Option::IgnoreMapFlagNoWait))
|
||||
if (!m_parent->TestOption(D3D11Option::AllowMapFlagNoWait))
|
||||
MapFlags &= ~D3D11_MAP_FLAG_DO_NOT_WAIT;
|
||||
|
||||
// Wait for the any pending D3D11 command to be executed
|
||||
|
@ -5,7 +5,7 @@
|
||||
namespace dxvk {
|
||||
|
||||
const static std::unordered_map<std::string, D3D11OptionSet> g_d3d11AppOptions = {{
|
||||
{ "witcher3.exe", D3D11OptionSet(D3D11Option::IgnoreMapFlagNoWait) },
|
||||
{ "Dishonored2.exe", D3D11OptionSet(D3D11Option::AllowMapFlagNoWait) },
|
||||
}};
|
||||
|
||||
|
||||
|
@ -5,11 +5,20 @@
|
||||
namespace dxvk {
|
||||
|
||||
enum class D3D11Option : uint64_t {
|
||||
IgnoreMapFlagNoWait = 0,
|
||||
/**
|
||||
* \brief Handle D3D11_MAP_FLAG_DO_NOT_WAIT properly
|
||||
*
|
||||
* This can offer substantial speedups, but some games
|
||||
* (The Witcher 3, Elder Scrolls Online, possibly others)
|
||||
* seem to make incorrect assumptions about when a map
|
||||
* operation succeeds when that flag is set.
|
||||
*/
|
||||
AllowMapFlagNoWait = 0,
|
||||
};
|
||||
|
||||
using D3D11OptionSet = Flags<D3D11Option>;
|
||||
|
||||
|
||||
/**
|
||||
* \brief Retrieves per-app options
|
||||
*
|
||||
|
Loading…
x
Reference in New Issue
Block a user