libktx Reference 4.3.2
Libraries and tools to create and read KTX image texture files.
Loading...
Searching...
No Matches
ktxVulkanDeviceInfo Class Reference

Struct for passing information about the Vulkan device on which to create images to the texture image loading functions. More...

#include <ktxvulkan.h>

Public Member Functions

ktxVulkanDeviceInfoktxVulkanDeviceInfo_Create (VkPhysicalDevice physicalDevice, VkDevice device, VkQueue queue, VkCommandPool cmdPool, const VkAllocationCallbacks *pAllocator)
 Create a ktxVulkanDeviceInfo object.
 
ktxVulkanDeviceInfoktxVulkanDeviceInfo_CreateEx (VkInstance instance, VkPhysicalDevice physicalDevice, VkDevice device, VkQueue queue, VkCommandPool cmdPool, const VkAllocationCallbacks *pAllocator, const ktxVulkanFunctions *pFuncs)
 Create a ktxVulkanDeviceInfo object.
 
KTX_error_code ktxVulkanDeviceInfo_Construct (ktxVulkanDeviceInfo *This, VkPhysicalDevice physicalDevice, VkDevice device, VkQueue queue, VkCommandPool cmdPool, const VkAllocationCallbacks *pAllocator)
 Construct a ktxVulkanDeviceInfo object.
 
KTX_error_code ktxVulkanDeviceInfo_ConstructEx (ktxVulkanDeviceInfo *This, VkInstance instance, VkPhysicalDevice physicalDevice, VkDevice device, VkQueue queue, VkCommandPool cmdPool, const VkAllocationCallbacks *pAllocator, const ktxVulkanFunctions *pFunctions)
 
void ktxVulkanDeviceInfo_Destruct (ktxVulkanDeviceInfo *This)
 Destruct a ktxVulkanDeviceInfo object.
 
void ktxVulkanDeviceInfo_Destroy (ktxVulkanDeviceInfo *This)
 Destroy a ktxVulkanDeviceInfo object.
 

Data Fields

VkInstance instance
 
VkPhysicalDevice physicalDevice
 
VkDevice device
 
VkQueue queue
 
VkCommandBuffer cmdBuffer
 
VkCommandPool cmdPool
 
const VkAllocationCallbacks * pAllocator
 
VkPhysicalDeviceMemoryProperties deviceMemoryProperties
 
ktxVulkanFunctions vkFuncs
 

Detailed Description

Struct for passing information about the Vulkan device on which to create images to the texture image loading functions.

Avoids passing a large number of parameters to each loading function. Use of ktxVulkanDeviceInfo_create() or ktxVulkanDeviceInfo_construct() to populate this structure is highly recommended.

vdi = ktxVulkanDeviceInfo_create(physicalDevice,
&allocator);
ktxLoadVkTextureN("texture_1.ktx", vdi, &texture, NULL, NULL);
// ...
ktxLoadVkTextureN("texture_n.ktx", vdi, &texture, NULL, NULL);
ktxVulkanDeviceInfo_destroy(vdi);
Struct for passing information about the Vulkan device on which to create images to the texture image...
Definition: ktxvulkan.h:188
VkDevice device
Definition: ktxvulkan.h:191
VkQueue queue
Definition: ktxvulkan.h:192
VkCommandPool cmdPool
Definition: ktxvulkan.h:195
VkPhysicalDevice physicalDevice
Definition: ktxvulkan.h:190
Struct for returning information about the Vulkan texture image created by the ktxTexture_VkUpload* f...
Definition: ktxvulkan.h:108
Examples
vkload.cpp.

Field Documentation

◆ cmdBuffer

VkCommandBuffer cmdBuffer

Handle of the cmdBuffer to use.

◆ cmdPool

VkCommandPool cmdPool

Handle of the command pool from which to allocate the command buffer.

◆ device

VkDevice device

Handle of the logical device.

◆ deviceMemoryProperties

VkPhysicalDeviceMemoryProperties deviceMemoryProperties

Memory properties of the Vulkan physical device.

◆ instance

VkInstance instance

Instance used to communicate with vulkan.

◆ pAllocator

const VkAllocationCallbacks* pAllocator

Pointer to the allocator to use for the command buffer and created images.

◆ physicalDevice

VkPhysicalDevice physicalDevice

Handle of the physical device.

◆ queue

VkQueue queue

Handle to the queue to which to submit commands.

◆ vkFuncs

The functions needed to operate functions