Skip to content

KDGpu::VulkanTexture

Module: Vulkan

VulkanTexture.

#include <vulkan_texture.h>

Inherits from KDGpu::ApiTexture

Public Functions

Name
VulkanTexture(VkImage _image, VmaAllocation _allocation, VmaAllocator _allocator, Format _format, Extent3D _extent, uint32_t _mipLevels, uint32_t _arrayLayers, TextureUsageFlags _usage, VulkanResourceManager * _vulkanResourceManager, const Handle< Device_t > & _deviceHandle, const MemoryHandle & _externalMemoryHandle, bool _ownedBySwapchain =false)
virtual void * map()
virtual void unmap()
virtual SubresourceLayout getSubresourceLayout(const TextureSubresource & subresource) const
virtual MemoryHandle externalMemoryHandle() const

Public Attributes

Name
VkImage image
VmaAllocation allocation
VmaAllocator allocator
void * mapped
Format format
Extent3D extent
uint32_t mipLevels
uint32_t arrayLayers
TextureUsageFlags usage
bool ownedBySwapchain
VulkanResourceManager * vulkanResourceManager
Handle< Device_t > deviceHandle
MemoryHandle m_externalMemoryHandle

Public Functions Documentation

function VulkanTexture

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
explicit VulkanTexture(
    VkImage _image,
    VmaAllocation _allocation,
    VmaAllocator _allocator,
    Format _format,
    Extent3D _extent,
    uint32_t _mipLevels,
    uint32_t _arrayLayers,
    TextureUsageFlags _usage,
    VulkanResourceManager * _vulkanResourceManager,
    const Handle< Device_t > & _deviceHandle,
    const MemoryHandle & _externalMemoryHandle,
    bool _ownedBySwapchain =false
)

function map

1
virtual void * map()

Reimplements: KDGpu::ApiTexture::map

function unmap

1
virtual void unmap()

Reimplements: KDGpu::ApiTexture::unmap

function getSubresourceLayout

1
2
3
virtual SubresourceLayout getSubresourceLayout(
    const TextureSubresource & subresource
) const

Reimplements: KDGpu::ApiTexture::getSubresourceLayout

function externalMemoryHandle

1
virtual MemoryHandle externalMemoryHandle() const

Reimplements: KDGpu::ApiTexture::externalMemoryHandle

Public Attributes Documentation

variable image

1
VkImage image { VK_NULL_HANDLE };

variable allocation

1
VmaAllocation allocation { VK_NULL_HANDLE };

variable allocator

1
VmaAllocator allocator { VK_NULL_HANDLE };

variable mapped

1
void * mapped { nullptr };

variable format

1
Format format;

variable extent

1
Extent3D extent;

variable mipLevels

1
uint32_t mipLevels;

variable arrayLayers

1
uint32_t arrayLayers;

variable usage

1
TextureUsageFlags usage;

variable ownedBySwapchain

1
bool ownedBySwapchain { false };

variable vulkanResourceManager

1
VulkanResourceManager * vulkanResourceManager { nullptr };

variable deviceHandle

1
Handle< Device_t > deviceHandle;

variable m_externalMemoryHandle

1
MemoryHandle m_externalMemoryHandle {};

Updated on 2024-09-08 at 00:13:09 +0000