Class CUarrayMapInfo

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

    public class CUarrayMapInfo
    extends org.lwjgl.system.Struct
    implements org.lwjgl.system.NativeResource
    Specifies the CUDA array or CUDA mipmapped array memory mapping information.

    Layout

    
     struct CUarrayMapInfo {
         CUresourcetype resourceType();
         union {
             CUmipmappedArray mipmap;
             CUarray array;
         } resource;
         CUarraySparseSubresourceType subresourceType();
         union {
             struct {
                 unsigned int level;
                 unsigned int layer;
                 unsigned int offsetX;
                 unsigned int offsetY;
                 unsigned int offsetZ;
                 unsigned int extentWidth;
                 unsigned int extentHeight;
                 unsigned int extentDepth;
             } sparseLevel;
             struct {
                 unsigned int layer;
                 unsigned long long offset;
                 unsigned long long size;
             } miptail;
         } subresource;
         CUmemOperationType memOperationType();
         CUmemHandleType memHandleType();
         union {
             CUmemGenericAllocationHandle memHandle;
         } memHandle;
         unsigned long long offset();
         unsigned int deviceBitMask();
         unsigned int flags();
         unsigned int reserved()[2];
     }
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.
      • RESOURCETYPE, RESOURCE, RESOURCE_MIPMAP, RESOURCE_ARRAY, SUBRESOURCETYPE, SUBRESOURCE, SUBRESOURCE_SPARSELEVEL, SUBRESOURCE_SPARSELEVEL_LEVEL, SUBRESOURCE_SPARSELEVEL_LAYER, SUBRESOURCE_SPARSELEVEL_OFFSETX, SUBRESOURCE_SPARSELEVEL_OFFSETY, SUBRESOURCE_SPARSELEVEL_OFFSETZ, SUBRESOURCE_SPARSELEVEL_EXTENTWIDTH, SUBRESOURCE_SPARSELEVEL_EXTENTHEIGHT, SUBRESOURCE_SPARSELEVEL_EXTENTDEPTH, SUBRESOURCE_MIPTAIL, SUBRESOURCE_MIPTAIL_LAYER, SUBRESOURCE_MIPTAIL_OFFSET, SUBRESOURCE_MIPTAIL_SIZE, MEMOPERATIONTYPE, MEMHANDLETYPE, MEMHANDLE, MEMHANDLE_MEMHANDLE, OFFSET, DEVICEBITMASK, FLAGS, RESERVED

        The struct member offsets.
    • Constructor Detail

      • CUarrayMapInfo

        public CUarrayMapInfo​(java.nio.ByteBuffer container)
        Creates a CUarrayMapInfo 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.

    • Method Detail

      • sizeof

        public int sizeof()
        Specified by:
        sizeof in class org.lwjgl.system.Struct
      • resourceType

        public int resourceType()
        resource type
      • resource_mipmap

        public long resource_mipmap()
        Returns:
        the value of the resource.mipmap field.
      • resource_array

        public long resource_array()
        Returns:
        the value of the resource.array field.
      • subresourceType

        public int subresourceType()
        sparse subresource type
      • subresource_sparseLevel_level

        public int subresource_sparseLevel_level()
        for CUDA mipmapped arrays must a valid mipmap level. For CUDA arrays must be zero
      • subresource_sparseLevel_layer

        public int subresource_sparseLevel_layer()
        for CUDA layered arrays must be a valid layer index. Otherwise, must be zero
      • subresource_sparseLevel_offsetX

        public int subresource_sparseLevel_offsetX()
        starting X offset in elements
      • subresource_sparseLevel_offsetY

        public int subresource_sparseLevel_offsetY()
        starting Y offset in elements
      • subresource_sparseLevel_offsetZ

        public int subresource_sparseLevel_offsetZ()
        starting Z offset in elements
      • subresource_sparseLevel_extentWidth

        public int subresource_sparseLevel_extentWidth()
        width in elements
      • subresource_sparseLevel_extentHeight

        public int subresource_sparseLevel_extentHeight()
        height in elements
      • subresource_sparseLevel_extentDepth

        public int subresource_sparseLevel_extentDepth()
        depth in elements
      • subresource_miptail_layer

        public int subresource_miptail_layer()
        for CUDA layered arrays must be a valid layer index. Otherwise, must be zero
      • subresource_miptail_offset

        public long subresource_miptail_offset()
        offset within mip tail
      • subresource_miptail_size

        public long subresource_miptail_size()
        extent in bytes
      • memOperationType

        public int memOperationType()
        memory operation type
      • memHandleType

        public int memHandleType()
        memory handle type
      • memHandle_memHandle

        public long memHandle_memHandle()
        Returns:
        the value of the memHandle.memHandle field.
      • offset

        public long offset()
        offset within the memory
      • deviceBitMask

        public int deviceBitMask()
        device ordinal bit mask
      • flags

        public int flags()
        flags for future use, must be zero now
      • reserved

        public java.nio.IntBuffer reserved()
        
        public int reserved​(int index)
        
        reserved for future use, must be zero now
      • resource_mipmap

        public CUarrayMapInfo resource_mipmap​(long value)
        Sets the specified value to the mipmap field.
      • resource_array

        public CUarrayMapInfo resource_array​(long value)
        Sets the specified value to the array field.
      • memHandle_memHandle

        public CUarrayMapInfo memHandle_memHandle​(long value)
        Sets the specified value to the memHandle field.
      • reserved

        public CUarrayMapInfo reserved​(java.nio.IntBuffer value)
        Copies the specified IntBuffer to the reserved() field.
      • reserved

        public CUarrayMapInfo reserved​(int index,
                                       int value)
        Sets the specified value at the specified index of the reserved() field.
      • set

        public CUarrayMapInfo set​(CUarrayMapInfo src)
        Copies the specified struct data to this struct.
        Parameters:
        src - the source struct
        Returns:
        this struct
      • malloc

        public static CUarrayMapInfo malloc()
        Returns a new CUarrayMapInfo instance allocated with memAlloc. The instance must be explicitly freed.
      • calloc

        public static CUarrayMapInfo calloc()
        Returns a new CUarrayMapInfo instance allocated with memCalloc. The instance must be explicitly freed.
      • create

        public static CUarrayMapInfo create()
        Returns a new CUarrayMapInfo instance allocated with BufferUtils.
      • create

        public static CUarrayMapInfo create​(long address)
        Returns a new CUarrayMapInfo instance for the specified memory address.
      • createSafe

        @Nullable
        public static CUarrayMapInfo createSafe​(long address)
        Like create, but returns null if address is NULL.
      • malloc

        public static CUarrayMapInfo.Buffer malloc​(int capacity)
        Returns a new CUarrayMapInfo.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
        Parameters:
        capacity - the buffer capacity
      • calloc

        public static CUarrayMapInfo.Buffer calloc​(int capacity)
        Returns a new CUarrayMapInfo.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
        Parameters:
        capacity - the buffer capacity
      • create

        public static CUarrayMapInfo.Buffer create​(long address,
                                                   int capacity)
        Create a CUarrayMapInfo.Buffer instance at the specified memory.
        Parameters:
        address - the memory address
        capacity - the buffer capacity
      • createSafe

        @Nullable
        public static CUarrayMapInfo.Buffer createSafe​(long address,
                                                       int capacity)
        Like create, but returns null if address is NULL.
      • malloc

        public static CUarrayMapInfo malloc​(org.lwjgl.system.MemoryStack stack)
        Returns a new CUarrayMapInfo instance allocated on the specified MemoryStack.
        Parameters:
        stack - the stack from which to allocate
      • calloc

        public static CUarrayMapInfo calloc​(org.lwjgl.system.MemoryStack stack)
        Returns a new CUarrayMapInfo instance allocated on the specified MemoryStack and initializes all its bits to zero.
        Parameters:
        stack - the stack from which to allocate
      • malloc

        public static CUarrayMapInfo.Buffer malloc​(int capacity,
                                                   org.lwjgl.system.MemoryStack stack)
        Returns a new CUarrayMapInfo.Buffer instance allocated on the specified MemoryStack.
        Parameters:
        stack - the stack from which to allocate
        capacity - the buffer capacity
      • calloc

        public static CUarrayMapInfo.Buffer calloc​(int capacity,
                                                   org.lwjgl.system.MemoryStack stack)
        Returns a new CUarrayMapInfo.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
        Parameters:
        stack - the stack from which to allocate
        capacity - the buffer capacity
      • nresourceType

        public static int nresourceType​(long struct)
        Unsafe version of resourceType().
      • nresource_mipmap

        public static long nresource_mipmap​(long struct)
        Unsafe version of resource_mipmap().
      • nresource_array

        public static long nresource_array​(long struct)
        Unsafe version of resource_array().
      • nsubresourceType

        public static int nsubresourceType​(long struct)
        Unsafe version of subresourceType().
      • nsubresource_miptail_layer

        public static int nsubresource_miptail_layer​(long struct)
        Unsafe version of subresource_miptail_layer().
      • nsubresource_miptail_offset

        public static long nsubresource_miptail_offset​(long struct)
        Unsafe version of subresource_miptail_offset().
      • nsubresource_miptail_size

        public static long nsubresource_miptail_size​(long struct)
        Unsafe version of subresource_miptail_size().
      • nmemOperationType

        public static int nmemOperationType​(long struct)
        Unsafe version of memOperationType().
      • nmemHandleType

        public static int nmemHandleType​(long struct)
        Unsafe version of memHandleType().
      • nmemHandle_memHandle

        public static long nmemHandle_memHandle​(long struct)
        Unsafe version of memHandle_memHandle().
      • noffset

        public static long noffset​(long struct)
        Unsafe version of offset().
      • ndeviceBitMask

        public static int ndeviceBitMask​(long struct)
        Unsafe version of deviceBitMask().
      • nflags

        public static int nflags​(long struct)
        Unsafe version of flags().
      • nreserved

        public static java.nio.IntBuffer nreserved​(long struct)
        Unsafe version of reserved().
      • nreserved

        public static int nreserved​(long struct,
                                    int index)
        Unsafe version of reserved.
      • nresourceType

        public static void nresourceType​(long struct,
                                         int value)
        Unsafe version of resourceType.
      • nresource_mipmap

        public static void nresource_mipmap​(long struct,
                                            long value)
        Unsafe version of resource_mipmap.
      • nresource_array

        public static void nresource_array​(long struct,
                                           long value)
        Unsafe version of resource_array.
      • nsubresourceType

        public static void nsubresourceType​(long struct,
                                            int value)
        Unsafe version of subresourceType.
      • nsubresource_sparseLevel_level

        public static void nsubresource_sparseLevel_level​(long struct,
                                                          int value)
      • nsubresource_sparseLevel_layer

        public static void nsubresource_sparseLevel_layer​(long struct,
                                                          int value)
      • nsubresource_sparseLevel_offsetX

        public static void nsubresource_sparseLevel_offsetX​(long struct,
                                                            int value)
      • nsubresource_sparseLevel_offsetY

        public static void nsubresource_sparseLevel_offsetY​(long struct,
                                                            int value)
      • nsubresource_sparseLevel_offsetZ

        public static void nsubresource_sparseLevel_offsetZ​(long struct,
                                                            int value)
      • nsubresource_sparseLevel_extentWidth

        public static void nsubresource_sparseLevel_extentWidth​(long struct,
                                                                int value)
      • nsubresource_sparseLevel_extentHeight

        public static void nsubresource_sparseLevel_extentHeight​(long struct,
                                                                 int value)
      • nsubresource_sparseLevel_extentDepth

        public static void nsubresource_sparseLevel_extentDepth​(long struct,
                                                                int value)
      • nsubresource_miptail_layer

        public static void nsubresource_miptail_layer​(long struct,
                                                      int value)
        Unsafe version of subresource_miptail_layer.
      • nsubresource_miptail_offset

        public static void nsubresource_miptail_offset​(long struct,
                                                       long value)
        Unsafe version of subresource_miptail_offset.
      • nsubresource_miptail_size

        public static void nsubresource_miptail_size​(long struct,
                                                     long value)
        Unsafe version of subresource_miptail_size.
      • nmemOperationType

        public static void nmemOperationType​(long struct,
                                             int value)
        Unsafe version of memOperationType.
      • nmemHandleType

        public static void nmemHandleType​(long struct,
                                          int value)
        Unsafe version of memHandleType.
      • nmemHandle_memHandle

        public static void nmemHandle_memHandle​(long struct,
                                                long value)
        Unsafe version of memHandle_memHandle.
      • noffset

        public static void noffset​(long struct,
                                   long value)
        Unsafe version of offset.
      • ndeviceBitMask

        public static void ndeviceBitMask​(long struct,
                                          int value)
        Unsafe version of deviceBitMask.
      • nflags

        public static void nflags​(long struct,
                                  int value)
        Unsafe version of flags.
      • nreserved

        public static void nreserved​(long struct,
                                     java.nio.IntBuffer value)
        Unsafe version of reserved.
      • nreserved

        public static void nreserved​(long struct,
                                     int index,
                                     int value)
        Unsafe version of reserved.