Class VkClearColorValue

All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer

public class VkClearColorValue extends Struct<VkClearColorValue> implements NativeResource

 union VkClearColorValue {
     float float32[4];
     int32_t int32[4];
     uint32_t uint32[4];
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • FLOAT32

      public static final int FLOAT32
      The struct member offsets.
    • INT32

      public static final int INT32
      The struct member offsets.
    • UINT32

      public static final int UINT32
      The struct member offsets.
  • Constructor Details

    • VkClearColorValue

      public VkClearColorValue(ByteBuffer container)
      Creates a VkClearColorValue 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 Details

    • sizeof

      public int sizeof()
      Description copied from class: Struct
      Returns sizeof(struct).
      Specified by:
      sizeof in class Struct<VkClearColorValue>
    • float32

      public FloatBuffer float32()
      Returns:
      a FloatBuffer view of the float32 field.
    • float32

      public float float32(int index)
      Returns:
      the value at the specified index of the float32 field.
    • int32

      public IntBuffer int32()
      Returns:
      a IntBuffer view of the int32 field.
    • int32

      public int int32(int index)
      Returns:
      the value at the specified index of the int32 field.
    • uint32

      public IntBuffer uint32()
      Returns:
      a IntBuffer view of the uint32 field.
    • uint32

      public int uint32(int index)
      Returns:
      the value at the specified index of the uint32 field.
    • float32

      public VkClearColorValue float32(FloatBuffer value)
      Copies the specified FloatBuffer to the float32 field.
    • float32

      public VkClearColorValue float32(int index, float value)
      Sets the specified value at the specified index of the float32 field.
    • int32

      public VkClearColorValue int32(IntBuffer value)
      Copies the specified IntBuffer to the int32 field.
    • int32

      public VkClearColorValue int32(int index, int value)
      Sets the specified value at the specified index of the int32 field.
    • uint32

      public VkClearColorValue uint32(IntBuffer value)
      Copies the specified IntBuffer to the uint32 field.
    • uint32

      public VkClearColorValue uint32(int index, int value)
      Sets the specified value at the specified index of the uint32 field.
    • set

      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

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

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

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

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

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

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

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

      public static VkClearColorValue.Buffer create(int capacity)
      Returns a new VkClearColorValue.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

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

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

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

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

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

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

      public static FloatBuffer nfloat32(long struct)
      Unsafe version of float32().
    • nfloat32

      public static float nfloat32(long struct, int index)
      Unsafe version of float32.
    • nint32

      public static IntBuffer nint32(long struct)
      Unsafe version of int32().
    • nint32

      public static int nint32(long struct, int index)
      Unsafe version of int32.
    • nuint32

      public static IntBuffer nuint32(long struct)
      Unsafe version of uint32().
    • nuint32

      public static int nuint32(long struct, int index)
      Unsafe version of uint32.
    • nfloat32

      public static void nfloat32(long struct, FloatBuffer value)
      Unsafe version of float32.
    • nfloat32

      public static void nfloat32(long struct, int index, float value)
      Unsafe version of float32.
    • nint32

      public static void nint32(long struct, IntBuffer value)
      Unsafe version of int32.
    • nint32

      public static void nint32(long struct, int index, int value)
      Unsafe version of int32.
    • nuint32

      public static void nuint32(long struct, IntBuffer value)
      Unsafe version of uint32.
    • nuint32

      public static void nuint32(long struct, int index, int value)
      Unsafe version of uint32.