Package icyllis.arc3d.vulkan

# Class VulkanBackendImage

java.lang.Object
icyllis.arc3d.engine.BackendImage
icyllis.arc3d.vulkan.VulkanBackendImage

public final class VulkanBackendImage extends BackendImage
When importing external memory, `mMemoryHandle` is POSIX file descriptor or Win32 NT handle (though `HANDLE` is defined as `void*`, we can safely truncate it because Win32 handles are 32-bit significant). If it is an NT handle, it must be released manually by the memory exporter (e.g. Vulkan).

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `int`
  `mLevelCount`
  `long`
  `mMemoryHandle`

  ### Fields inherited from class icyllis.arc3d.engine.BackendImage

  `mDesc, mMutableState`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `VulkanBackendImage(int width, int height, VulkanImageDesc desc)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getBackend()`
  `BackendFormat`
  `getBackendFormat()`
  Get the BackendFormat for this image/texture.
  `boolean`
  `isExternal()`
  `boolean`
  `isProtected()`
  Returns true if we are working with protected content.
  `boolean`
  `isSameImage(BackendImage image)`
  Returns true if both images are valid and refer to the same API image handle.
  `void`
  `setVkImageLayout(int layout)`
  Anytime the client changes the VkImageLayout of the VkImage captured by this `BackendImage`, they must call this function to notify pipeline of the changed layout.
  `void`
  `setVkQueueFamilyIndex(int queueFamilyIndex)`
  Anytime the client changes the QueueFamilyIndex of the VkImage captured by this `BackendImage`, they must call this function to notify pipeline of the changed layout.

  ### Methods inherited from class icyllis.arc3d.engine.BackendImage

  `getArraySize, getDepth, getDesc, getHeight, getImageType, getMipLevelCount, getMutableState, getWidth, glTextureParametersModified, isMipmapped`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### mLevelCount

    public int mLevelCount

  - ### mMemoryHandle

    public long mMemoryHandle

- ## Constructor Details

  - ### VulkanBackendImage

    public VulkanBackendImage(int width, int height, VulkanImageDesc desc)

- ## Method Details

  - ### getBackend

    public int getBackend()
    Specified by:
      `getBackend` in class `BackendImage`
    Returns:
      see `Engine.BackendApi`

  - ### isExternal

    public boolean isExternal()
    Specified by:
      `isExternal` in class `BackendImage`
    Returns:
      external texture

  - ### setVkImageLayout

    public void setVkImageLayout(int layout)
    Description copied from class: `BackendImage`
    Anytime the client changes the VkImageLayout of the VkImage captured by this `BackendImage`, they must call this function to notify pipeline of the changed layout.
    Overrides:
      `setVkImageLayout` in class `BackendImage`

  - ### setVkQueueFamilyIndex

    public void setVkQueueFamilyIndex(int queueFamilyIndex)
    Description copied from class: `BackendImage`
    Anytime the client changes the QueueFamilyIndex of the VkImage captured by this `BackendImage`, they must call this function to notify pipeline of the changed layout.
    Overrides:
      `setVkQueueFamilyIndex` in class `BackendImage`

  - ### getBackendFormat

    @Nonnull public BackendFormat getBackendFormat()
    Description copied from class: `BackendImage`
    Get the BackendFormat for this image/texture.
    Specified by:
      `getBackendFormat` in class `BackendImage`

  - ### isProtected

    public boolean isProtected()
    Description copied from class: `BackendImage`
    Returns true if we are working with protected content.
    Specified by:
      `isProtected` in class `BackendImage`

  - ### isSameImage

    public boolean isSameImage(BackendImage image)
    Description copied from class: `BackendImage`
    Returns true if both images are valid and refer to the same API image handle.
    Specified by:
      `isSameImage` in class `BackendImage`