Fixed major bug occurring on D3D12_RESOURCE_HEAP_TIER_1

Closes #11
This commit is contained in:
Adam Sawicki 2021-05-05 12:30:02 +02:00
parent 4dedc35e8f
commit 17df03f5ff

View File

@ -4693,7 +4693,7 @@ HRESULT AllocatorPimpl::CreateResource(
CommittedAllocationParameters committedAllocationParams = {};
bool preferCommitted = false;
HRESULT hr = CalcAllocationParams<D3D12_RESOURCE_DESC>(*pAllocDesc, resAllocInfo.SizeInBytes,
NULL, // pResDesc
pResourceDesc,
blockVector, committedAllocationParams, preferCommitted);
if(FAILED(hr))
return hr;
@ -4763,7 +4763,7 @@ HRESULT AllocatorPimpl::CreateResource1(
CommittedAllocationParameters committedAllocationParams = {};
bool preferCommitted = false;
HRESULT hr = CalcAllocationParams<D3D12_RESOURCE_DESC>(*pAllocDesc, resAllocInfo.SizeInBytes,
NULL, // pResDesc
pResourceDesc,
blockVector, committedAllocationParams, preferCommitted);
if(FAILED(hr))
return hr;
@ -4814,8 +4814,8 @@ HRESULT AllocatorPimpl::CreateResource2(
BlockVector* blockVector = NULL;
CommittedAllocationParameters committedAllocationParams = {};
bool preferCommitted = false;
HRESULT hr = CalcAllocationParams<D3D12_RESOURCE_DESC>(*pAllocDesc, resAllocInfo.SizeInBytes,
NULL, // pResDesc
HRESULT hr = CalcAllocationParams<D3D12_RESOURCE_DESC1>(*pAllocDesc, resAllocInfo.SizeInBytes,
pResourceDesc,
blockVector, committedAllocationParams, preferCommitted);
if(FAILED(hr))
return hr;