1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-18 20:52:10 +01:00

[dxbc] Remove Tex2D -> Tex2DArray workaround

This commit is contained in:
Philip Rebohle 2018-05-24 11:49:12 +02:00
parent d9772b0ffd
commit 58e9280891
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
4 changed files with 1 additions and 21 deletions

View File

@ -413,9 +413,6 @@ namespace dxvk {
viewInfo.numLevels = desc.Texture2D.MipLevels;
viewInfo.minLayer = 0;
viewInfo.numLayers = 1;
if (m_dxbcOptions.test(DxbcOption::ForceTex2DArray))
viewInfo.type = VK_IMAGE_VIEW_TYPE_2D_ARRAY;
break;
case D3D11_SRV_DIMENSION_TEXTURE2DARRAY:
@ -432,9 +429,6 @@ namespace dxvk {
viewInfo.numLevels = 1;
viewInfo.minLayer = 0;
viewInfo.numLayers = 1;
if (m_dxbcOptions.test(DxbcOption::ForceTex2DArray))
viewInfo.type = VK_IMAGE_VIEW_TYPE_2D_ARRAY;
break;
case D3D11_SRV_DIMENSION_TEXTURE2DMSARRAY:
@ -624,9 +618,6 @@ namespace dxvk {
viewInfo.numLevels = 1;
viewInfo.minLayer = 0;
viewInfo.numLayers = 1;
if (m_dxbcOptions.test(DxbcOption::ForceTex2DArray))
viewInfo.type = VK_IMAGE_VIEW_TYPE_2D_ARRAY;
break;
case D3D11_UAV_DIMENSION_TEXTURE2DARRAY:

View File

@ -6290,11 +6290,6 @@ namespace dxvk {
}
}();
if (typeInfo.dim == spv::Dim2D && m_options.test(DxbcOption::ForceTex2DArray)) {
typeInfo.array = 1;
typeInfo.vtype = VK_IMAGE_VIEW_TYPE_2D_ARRAY;
}
return typeInfo;
}

View File

@ -5,8 +5,7 @@
namespace dxvk {
const static std::unordered_map<std::string, DxbcOptions> g_dxbcAppOptions = {{
{ "Dishonored2.exe", DxbcOptions(DxbcOption::ForceTex2DArray) },
{ "ManiaPlanet.exe", DxbcOptions(DxbcOption::ForceTex2DArray) },
}};

View File

@ -17,11 +17,6 @@ namespace dxvk {
/// Use FMin/FMax/FClamp instead of NMin/NMax/NClamp.
/// Workaround for bugs in older Nvidia drivers.
UseSimpleMinMaxClamp,
/// Enforces the use of array views even when dealing
/// with non-array texture types. Some games do not
/// bind the correct texture type to the pipeline.
ForceTex2DArray,
};
using DxbcOptions = Flags<DxbcOption>;