File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed
Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -817,11 +817,9 @@ static bool ValidateAllocateMemoryParameters(
817817 return pAllocDesc &&
818818 pAllocInfo &&
819819 ppAllocation &&
820- (pAllocInfo->Alignment == 0 ||
821- pAllocInfo->Alignment == D3D12_DEFAULT_RESOURCE_PLACEMENT_ALIGNMENT ||
822- pAllocInfo->Alignment == D3D12_DEFAULT_MSAA_RESOURCE_PLACEMENT_ALIGNMENT) &&
823- pAllocInfo->SizeInBytes != 0 &&
824- pAllocInfo->SizeInBytes % (64ull * 1024 ) == 0 ;
820+ IsPow2 (pAllocInfo->Alignment ) &&
821+ pAllocInfo->SizeInBytes > 0 &&
822+ pAllocInfo->SizeInBytes % 4 == 0 ;
825823}
826824
827825#endif // _D3D12MA_FUNCTIONS
@@ -9880,7 +9878,7 @@ HRESULT Allocator::AllocateMemory(
98809878 return E_INVALIDARG;
98819879 }
98829880 D3D12MA_DEBUG_GLOBAL_MUTEX_LOCK
9883- return m_Pimpl->AllocateMemory (pAllocDesc, pAllocInfo, ppAllocation);
9881+ return m_Pimpl->AllocateMemory (pAllocDesc, pAllocInfo, ppAllocation);
98849882}
98859883
98869884HRESULT Allocator::CreateAliasingResource (
You can’t perform that action at this time.
0 commit comments