VKMemoryAllocator::Alloc() use new name AllocMemory().
This commit is contained in:
parent
666bedbf85
commit
1dc5dd09a7
@ -15,7 +15,7 @@ class VKMemoryAllocator:public AbstractMemoryAllocator
|
|||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
bool Alloc() override;
|
bool AllocMemory() override;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ VKMemoryAllocator::VKMemoryAllocator(GPUDevice *d,const uint32_t flags)
|
|||||||
|
|
||||||
const GPUPhysicalDevice *pd=device->GetPhysicalDevice();
|
const GPUPhysicalDevice *pd=device->GetPhysicalDevice();
|
||||||
|
|
||||||
SetAllocUnitSize(pd->GetConstantSize()); //据说push constant容量就是GPU的最小访问单位
|
SetAllocUnitSize(pd->GetUBOAlign());
|
||||||
}
|
}
|
||||||
|
|
||||||
VKMemoryAllocator::~VKMemoryAllocator()
|
VKMemoryAllocator::~VKMemoryAllocator()
|
||||||
@ -24,7 +24,7 @@ VKMemoryAllocator::~VKMemoryAllocator()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool VKMemoryAllocator::Alloc()
|
bool VKMemoryAllocator::AllocMemory()
|
||||||
{
|
{
|
||||||
if(gpu_buffer)
|
if(gpu_buffer)
|
||||||
delete gpu_buffer;
|
delete gpu_buffer;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user