Hymn to Beauty
C++ 3D Engine
Video::VulkanRawBuffer Class Reference

Vulkan implementation of RawBuffer. More...

#include <VulkanBufferAllocator.hpp>

Inheritance diagram for Video::VulkanRawBuffer:
Video::RawBuffer

Public Member Functions

 VulkanRawBuffer (VulkanRenderer &vulkanRenderer, VkDevice device, VkPhysicalDevice physicalDevice, Buffer::BufferUsage bufferUsage, bool temporary, unsigned int size)
 Create new raw buffer used to satisfy allocations. More...
 
 ~VulkanRawBuffer () final
 Destructor. More...
 
void Write (uint32_t offset, uint32_t size, const void *data) final
 Write data to buffer. More...
 
VkBuffer GetBuffer () const
 Get the internal Vulkan buffer. More...
 
VkDeviceMemory GetDeviceMemory () const
 Get the device memory. More...
 
- Public Member Functions inherited from Video::RawBuffer
virtual ~RawBuffer ()
 Destructor. More...
 

Detailed Description

Vulkan implementation of RawBuffer.

Constructor & Destructor Documentation

◆ VulkanRawBuffer()

Video::VulkanRawBuffer::VulkanRawBuffer ( VulkanRenderer vulkanRenderer,
VkDevice  device,
VkPhysicalDevice  physicalDevice,
Buffer::BufferUsage  bufferUsage,
bool  temporary,
unsigned int  size 
)

Create new raw buffer used to satisfy allocations.

Parameters
vulkanRendererThe Vulkan renderer.
deviceThe Vulkan device.
physicalDeviceThe physical device.
bufferUsageHow the buffer will be used.
temporaryWhether the buffer is going to be used to satisfy temporary allocations.
sizeThe size of the buffer in bytes.

◆ ~VulkanRawBuffer()

Video::VulkanRawBuffer::~VulkanRawBuffer ( )
final

Destructor.

Member Function Documentation

◆ GetBuffer()

VkBuffer Video::VulkanRawBuffer::GetBuffer ( ) const

Get the internal Vulkan buffer.

Returns
The internal Vulkan buffer.

◆ GetDeviceMemory()

VkDeviceMemory Video::VulkanRawBuffer::GetDeviceMemory ( ) const

Get the device memory.

Returns
The device memory.

◆ Write()

void Video::VulkanRawBuffer::Write ( uint32_t  offset,
uint32_t  size,
const void *  data 
)
finalvirtual

Write data to buffer.

Parameters
offsetThe offset (in bytes) into the buffer to write at.
sizeThe size of the data to write (in bytes).
dataThe data to write.

Implements Video::RawBuffer.


The documentation for this class was generated from the following files: