mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-22 14:36:35 +00:00
Make sure to correctly identify removed buffer in GPUAddress mapping
* When multiple buffers are aliased over the same heap memory, they'll have the same GPU base address. Our mapping needs to ensure it removes the right entry when a resource is released.
This commit is contained in:
@@ -307,7 +307,14 @@ WrappedID3D12Resource::~WrappedID3D12Resource()
|
||||
|
||||
// assuming only valid for buffers
|
||||
if(m_pReal->GetDesc().Dimension == D3D12_RESOURCE_DIMENSION_BUFFER)
|
||||
m_Addresses.RemoveFrom(m_pReal->GetGPUVirtualAddress());
|
||||
{
|
||||
GPUAddressRange range;
|
||||
range.start = m_pReal->GetGPUVirtualAddress();
|
||||
range.end = m_pReal->GetGPUVirtualAddress() + m_pReal->GetDesc().Width;
|
||||
range.id = GetResourceID();
|
||||
|
||||
m_Addresses.RemoveFrom(range);
|
||||
}
|
||||
|
||||
Shutdown();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user