Class VkImportMemoryFdInfoKHR

  • All Implemented Interfaces:
    java.lang.AutoCloseable, NativeResource, Pointer

    public class VkImportMemoryFdInfoKHR
    extends Struct
    implements NativeResource
    import memory created on the same physical device from a file descriptor.
    Description

    Importing memory from a file descriptor transfers ownership of the file descriptor from the application to the Vulkan implementation. The application must not perform any operations on the file descriptor after a successful import.

    Applications can import the same underlying memory into multiple instances of Vulkan, into the same instance from which it was exported, and multiple times into a given Vulkan instance. In all cases, each import operation must create a distinct VkDeviceMemory object.

    Valid Usage
    Valid Usage (Implicit)

    Member documentation

    • sType – the type of this structure.
    • pNextNULL or a pointer to an extension-specific structure.
    • handleType – specifies the handle type of fd.
    • fd – the external handle to import.

    Layout

    
     struct VkImportMemoryFdInfoKHR {
         VkStructureType sType;
         void const * pNext;
         VkExternalMemoryHandleTypeFlagBits handleType;
         int fd;
     }
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.
      • STYPE, PNEXT, HANDLETYPE, FD

        The struct member offsets.
    • Constructor Detail

      • VkImportMemoryFdInfoKHR

        public VkImportMemoryFdInfoKHR​(java.nio.ByteBuffer container)
        Creates a VkImportMemoryFdInfoKHR instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

        The created instance holds a strong reference to the container object.