mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-30 05:40:53 +00:00
Only ask for virtual address of buffers
This commit is contained in:
@@ -906,7 +906,7 @@ bool WrappedID3D12Device::Serialise_CreateCommittedResource(
|
||||
SERIALISE_ELEMENT(ResourceId, Res, ((WrappedID3D12Resource *)*ppvResource)->GetResourceID());
|
||||
|
||||
SERIALISE_ELEMENT(uint64_t, gpuAddress,
|
||||
((WrappedID3D12Resource *)*ppvResource)->GetGPUVirtualAddress());
|
||||
((WrappedID3D12Resource *)*ppvResource)->GetGPUVirtualAddressIfBuffer());
|
||||
|
||||
if(m_State == READING)
|
||||
{
|
||||
|
||||
@@ -722,6 +722,13 @@ public:
|
||||
void AllocShadow(UINT Subresource, size_t size);
|
||||
void FreeShadow();
|
||||
|
||||
virtual uint64_t GetGPUVirtualAddressIfBuffer()
|
||||
{
|
||||
if(m_pReal->GetDesc().Dimension == D3D12_RESOURCE_DIMENSION_BUFFER)
|
||||
return m_pReal->GetGPUVirtualAddress();
|
||||
return 0;
|
||||
}
|
||||
|
||||
//////////////////////////////
|
||||
// implement ID3D12Resource
|
||||
|
||||
|
||||
Reference in New Issue
Block a user