mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-07-13 11:07:08 +00:00
Fixes for D3D12 structured export
This commit is contained in:
@@ -284,7 +284,8 @@ WrappedID3D12Device::WrappedID3D12Device(ID3D12Device *realDevice, D3D12InitPara
|
||||
RDCDEBUG("Couldn't get ID3D12InfoQueue.");
|
||||
}
|
||||
|
||||
m_InitParams = *params;
|
||||
if(params)
|
||||
m_InitParams = *params;
|
||||
}
|
||||
|
||||
WrappedID3D12Device::~WrappedID3D12Device()
|
||||
@@ -2557,6 +2558,11 @@ ReplayStatus WrappedID3D12Device::ReadLogInitialisation(RDCFile *rdc, bool store
|
||||
// read the remaining data into memory and pass to immediate context
|
||||
frameDataSize = reader->GetSize() - reader->GetOffset();
|
||||
|
||||
if(IsStructuredExporting(m_State))
|
||||
{
|
||||
m_Queue = new WrappedID3D12CommandQueue(NULL, this, m_State);
|
||||
}
|
||||
|
||||
m_Queue->SetFrameReader(new StreamReader(reader, frameDataSize));
|
||||
|
||||
if(!IsStructuredExporting(m_State))
|
||||
|
||||
@@ -416,6 +416,7 @@ public:
|
||||
m_InitParams = params;
|
||||
m_SectionVersion = sectionVersion;
|
||||
}
|
||||
CaptureState GetState() { return m_State; }
|
||||
D3D12Replay *GetReplay() { return &m_Replay; }
|
||||
WrappedID3D12CommandQueue *GetQueue() { return m_Queue; }
|
||||
ID3D12CommandAllocator *GetAlloc() { return m_Alloc; }
|
||||
|
||||
@@ -289,6 +289,8 @@ template <typename SerialiserType>
|
||||
bool D3D12ResourceManager::Serialise_InitialState(SerialiserType &ser, ResourceId resid,
|
||||
ID3D12DeviceChild *liveRes)
|
||||
{
|
||||
m_State = m_Device->GetState();
|
||||
|
||||
D3D12ResourceRecord *record = NULL;
|
||||
D3D12InitialContents initContents;
|
||||
if(ser.IsWriting())
|
||||
|
||||
Reference in New Issue
Block a user