Skip to content

Commit

Permalink
[d3d9] Do not enable support for DF formats on Nvidia
Browse files Browse the repository at this point in the history
  • Loading branch information
WinterSnowfall authored and Joshua-Ashton committed May 18, 2024
1 parent 0c2efda commit 20185a5
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
4 changes: 3 additions & 1 deletion dxvk.conf
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,9 @@

# Support DF formats
#
# Support the vendor extension DF floating point depth formats
# Support the vendor extension DF floating point depth formats on AMD and Intel.
# Note that this config is ignored and disabled by default on Nvidia, or when
# spoofing a Nvidia GPU, as it does not support these formats natively.
#
# Supported values:
# - True/False
Expand Down
6 changes: 5 additions & 1 deletion src/d3d9/d3d9_format.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,11 @@ namespace dxvk {
D3D9VkFormatTable::D3D9VkFormatTable(
const Rc<DxvkAdapter>& adapter,
const D3D9Options& options) {
m_dfSupport = options.supportDFFormats;

const auto& props = adapter->deviceProperties();
uint32_t vendorId = options.customVendorId == -1 ? props.vendorID : uint32_t(options.customVendorId);

m_dfSupport = options.supportDFFormats && DxvkGpuVendor(vendorId) != DxvkGpuVendor::Nvidia;
m_x4r4g4b4Support = options.supportX4R4G4B4;
m_d32supportFinal = options.supportD32;

Expand Down

0 comments on commit 20185a5

Please sign in to comment.