Don't recreate heaps as displayable

This commit is contained in:
baldurk committed 2024-03-02 00:14:31 +00:00
1 parent 9500ebd94b
commit 9348bb4510
3 files changed
+9

No files matched your search

@@ -71,6 +71,9 @@ bool WrappedID3D12Device::Serialise_CreateResource(
// don't create resources non-resident
HeapFlags &= ~D3D12_HEAP_FLAG_CREATE_NOT_RESIDENT;
// don't create displayable heaps (?!)
HeapFlags &= ~D3D12_HEAP_FLAG_ALLOW_DISPLAY;
if(desc.Dimension == D3D12_RESOURCE_DIMENSION_BUFFER && gpuAddress != 0)
{
GPUAddressRange range;
@@ -1476,6 +1476,9 @@ bool WrappedID3D12Device::Serialise_CreateHeap(SerialiserType &ser, const D3D12_
// don't create resources non-resident
Descriptor.Flags &= ~D3D12_HEAP_FLAG_CREATE_NOT_RESIDENT;
// don't create displayable heaps (?!)
Descriptor.Flags &= ~D3D12_HEAP_FLAG_ALLOW_DISPLAY;
if(m_DriverInfo.vendor == GPUVendor::Software &&
Descriptor.Properties.Type == D3D12_HEAP_TYPE_CUSTOM)
Descriptor.Properties.MemoryPoolPreference = D3D12_MEMORY_POOL_L0;
@@ -249,6 +249,9 @@ bool WrappedID3D12Device::Serialise_CreateHeap1(SerialiserType &ser, const D3D12
// don't create resources non-resident
Descriptor.Flags &= ~D3D12_HEAP_FLAG_CREATE_NOT_RESIDENT;
// don't create displayable heaps (?!)
Descriptor.Flags &= ~D3D12_HEAP_FLAG_ALLOW_DISPLAY;
// don't replay with a protected session
HRESULT hr = E_NOINTERFACE;
if(m_pDevice4)