diff --git a/renderdoc/driver/d3d12/d3d12_device.cpp b/renderdoc/driver/d3d12/d3d12_device.cpp index f8cf1b777..2add2afea 100644 --- a/renderdoc/driver/d3d12/d3d12_device.cpp +++ b/renderdoc/driver/d3d12/d3d12_device.cpp @@ -3542,7 +3542,7 @@ void QueueReadbackData::Resize(uint64_t size) void WrappedID3D12Device::CreateInternalResources() { - if(IsReplayMode(m_State)) + if(IsReplayMode(m_State) && m_DriverInfo.vendor == GPUVendor::AMD) { // Initialise AMD extension, if possible HMODULE mod = GetModuleHandleA("amdxc64.dll"); diff --git a/renderdoc/driver/d3d12/d3d12_device.h b/renderdoc/driver/d3d12/d3d12_device.h index a8600ebae..75770a5c7 100644 --- a/renderdoc/driver/d3d12/d3d12_device.h +++ b/renderdoc/driver/d3d12/d3d12_device.h @@ -712,6 +712,8 @@ private: bool m_UsedDXIL = false; + DriverInformation m_DriverInfo = {}; + D3D12InitParams m_InitParams; uint64_t m_SectionVersion; ReplayOptions m_ReplayOptions; @@ -857,6 +859,7 @@ public: } const std::map &GetBackbufferFormats() { return m_BackbufferFormat; } void SetLogFile(const char *logfile); + void SetDriverInfo(const DriverInformation &info) { m_DriverInfo = info; } void SetInitParams(const D3D12InitParams ¶ms, uint64_t sectionVersion, const ReplayOptions &opts, INVAPID3DDevice *nvapi, IAGSD3DDevice *ags) { diff --git a/renderdoc/driver/d3d12/d3d12_replay.cpp b/renderdoc/driver/d3d12/d3d12_replay.cpp index e93543f86..eb580a323 100644 --- a/renderdoc/driver/d3d12/d3d12_replay.cpp +++ b/renderdoc/driver/d3d12/d3d12_replay.cpp @@ -114,6 +114,8 @@ void D3D12Replay::Initialise(IDXGIFactory1 *factory) SAFE_RELEASE(pDXGIAdapter); } } + + m_pDevice->SetDriverInfo(m_DriverInfo); } RDResult D3D12Replay::FatalErrorCheck()