Big buffer refactor

Replaced RenderBuffer class, replaced AbstractBuffer by Buffer
This commit is contained in:
Jérôme Leclercq
2022-01-23 00:05:08 +01:00
parent 754a0016c7
commit 29786765c6
98 changed files with 699 additions and 1427 deletions

View File

@@ -79,7 +79,7 @@ namespace Nz
OpenGLDevice::~OpenGLDevice()
{
// Free context first as it will unregister itself from m_contexts
// Free reference context first as it will unregister itself from m_contexts
m_referenceContext.reset();
}
@@ -114,9 +114,9 @@ namespace Nz
return m_deviceInfo.features;
}
std::shared_ptr<AbstractBuffer> OpenGLDevice::InstantiateBuffer(BufferType type)
std::shared_ptr<RenderBuffer> OpenGLDevice::InstantiateBuffer(BufferType type, UInt64 size, BufferUsageFlags usageFlags, const void* initialData)
{
return std::make_shared<OpenGLBuffer>(*this, type);
return std::make_shared<OpenGLBuffer>(*this, type, size, usageFlags, initialData);
}
std::shared_ptr<CommandPool> OpenGLDevice::InstantiateCommandPool(QueueType /*queueType*/)