Class VkClearRect

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


    public class VkClearRect
    extends Struct
    Khronos Reference Page
    Vulkan Specification

    Defines a region within an attachment to clear.

    Member documentation

    • rect – the two-dimensional region to be cleared
    • baseArrayLayer – the first layer to be cleared
    • layerCount – the number of layers to clear

    Layout

    struct VkClearRect {
        VkRect2D rect;
        uint32_t baseArrayLayer;
        uint32_t layerCount;
    }
    • Field Detail

      • SIZEOF

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

      • VkClearRect

        public VkClearRect(java.nio.ByteBuffer container)
        Creates a VkClearRect 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()
        Description copied from class: Struct
        Returns the sizeof(struct).
        Specified by:
        sizeof in class Struct
      • baseArrayLayer

        public int baseArrayLayer()
        Returns the value of the baseArrayLayer field.
      • layerCount

        public int layerCount()
        Returns the value of the layerCount field.
      • baseArrayLayer

        public VkClearRect baseArrayLayer(int value)
        Sets the specified value to the baseArrayLayer field.
      • layerCount

        public VkClearRect layerCount(int value)
        Sets the specified value to the layerCount field.
      • set

        public VkClearRect set(VkRect2D rect,
                               int baseArrayLayer,
                               int layerCount)
        Initializes this struct with the specified values.
      • set

        public VkClearRect set(VkClearRect src)
        Copies the specified struct data to this struct.
        Parameters:
        src - the source struct
        Returns:
        this struct
      • create

        public static VkClearRect create(long address)
        Returns a new VkClearRect instance for the specified memory address or null if the address is NULL.
      • create

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

        public static VkClearRect callocStack()
        Returns a new VkClearRect instance allocated on the thread-local MemoryStack and initializes all its bits to zero.
      • callocStack

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

        public static VkClearRect.Buffer callocStack(int capacity)
        Returns a new VkClearRect.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero.
        Parameters:
        capacity - the buffer capacity
      • callocStack

        public static VkClearRect.Buffer callocStack(int capacity,
                                                     MemoryStack stack)
        Returns a new VkClearRect.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