Vulkan specific implemetation of ImageBuffer class.
More...
#include <VulkanBuffer.h>
|
| VulkanImageBuffer (const char *filename) |
| Creates a GPU memory buffer for storing image texture.
|
|
virtual | ~VulkanImageBuffer () |
| Frees up device resources.
|
|
void | CreateBuffer (VkDeviceSize size, VkBufferUsageFlags usage, VkMemoryPropertyFlags properties, VkBuffer &buffer, VkDeviceMemory &bufferMemory) |
| Creates Vulkan buffer (VKbuffer) for image texture's use and allocates device memory appropriately.
|
|
uint32_t | FindMemoryType (uint32_t typeFilter, VkMemoryPropertyFlags properties) |
| Finds appropriate memory type with demanded properties. Basically a loop is run from counter i = 0 to VkPhysicalDeviceMemoryProperties.memoryTypeCount (number of valid elements in the memoryTypes array) and memoryType[i] is queried for appropriate properties. On condition satisfaction, counter i is returned.
|
|
const VkBuffer & | GetBuffer () const |
|
int | GetTextureWidth () const |
| Getter for the width (in pixels?) of the image texture.
|
|
int | GetTextureHeight () const |
| Getter for the height (in pixels?) of the image texture.
|
|
int | GetTextureChannels () const |
| Getter for desired channels (if non-zero, # of image components requested in result).
|
|
uint32_t | GetBindingPointIndex () const |
|
|
static ImageBuffer * | Create (const char *filename) |
|
uint32_t | m_BindingPoint |
|
Vulkan specific implemetation of ImageBuffer class.
◆ VulkanImageBuffer()
Karma::VulkanImageBuffer::VulkanImageBuffer |
( |
const char * | filename | ) |
|
Creates a GPU memory buffer for storing image texture.
- Parameters
-
filename | The path to the file, including filename, containing the image texture |
- Since
- Karma 1.0.0
◆ ~VulkanImageBuffer()
Karma::VulkanImageBuffer::~VulkanImageBuffer |
( |
| ) |
|
|
virtual |
Frees up device resources.
- Since
- Karma 1.0.0
◆ CreateBuffer()
void Karma::VulkanImageBuffer::CreateBuffer |
( |
VkDeviceSize | size, |
|
|
VkBufferUsageFlags | usage, |
|
|
VkMemoryPropertyFlags | properties, |
|
|
VkBuffer & | buffer, |
|
|
VkDeviceMemory & | bufferMemory ) |
◆ FindMemoryType()
uint32_t Karma::VulkanImageBuffer::FindMemoryType |
( |
uint32_t | typeFilter, |
|
|
VkMemoryPropertyFlags | properties ) |
Finds appropriate memory type with demanded properties. Basically a loop is run from counter i = 0 to VkPhysicalDeviceMemoryProperties.memoryTypeCount (number of valid elements in the memoryTypes array) and memoryType[i] is queried for appropriate properties. On condition satisfaction, counter i is returned.
- Parameters
-
- Returns
- Memory type index i
- Since
- Karma 1.0.0
◆ GetTextureChannels()
int Karma::VulkanImageBuffer::GetTextureChannels |
( |
| ) |
const |
|
inline |
◆ GetTextureHeight()
int Karma::VulkanImageBuffer::GetTextureHeight |
( |
| ) |
const |
|
inline |
Getter for the height (in pixels?) of the image texture.
- Since
- Karma 1.0.0
◆ GetTextureWidth()
int Karma::VulkanImageBuffer::GetTextureWidth |
( |
| ) |
const |
|
inline |
Getter for the width (in pixels?) of the image texture.
- Since
- Karma 1.0.0
The documentation for this class was generated from the following files:
- Karma/src/Platform/Vulkan/VulkanBuffer.h
- Karma/src/Platform/Vulkan/VulkanBuffer.cpp