Package org.lwjgl.vulkan
Class VkClearRect
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkClearRect
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class VkClearRect extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
Structure specifying a clear rectangle.Description
The layers
[baseArrayLayer, baseArrayLayer + layerCount)
counting from the base layer of the attachment image view are cleared.See Also
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; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
VkClearRect.Buffer
An array ofVkClearRect
structs.
-
Field Summary
Fields Modifier and Type Field Description static int
ALIGNOF
The struct alignment in bytes.static int
BASEARRAYLAYER
LAYERCOUNT
RECTThe struct member offsets.static int
SIZEOF
The struct size in bytes.
-
Constructor Summary
Constructors Constructor Description VkClearRect(java.nio.ByteBuffer container)
Creates aVkClearRect
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
baseArrayLayer()
Returns the value of thebaseArrayLayer
field.VkClearRect
baseArrayLayer(int value)
Sets the specified value to thebaseArrayLayer
field.static VkClearRect
calloc()
Returns a newVkClearRect
instance allocated withmemCalloc
.static VkClearRect.Buffer
calloc(int capacity)
Returns a newVkClearRect.Buffer
instance allocated withmemCalloc
.static VkClearRect
callocStack()
Returns a newVkClearRect
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkClearRect.Buffer
callocStack(int capacity)
Returns a newVkClearRect.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkClearRect.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkClearRect
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkClearRect
create()
Returns a newVkClearRect
instance allocated withBufferUtils
.static VkClearRect.Buffer
create(int capacity)
Returns a newVkClearRect.Buffer
instance allocated withBufferUtils
.static VkClearRect
create(long address)
Returns a newVkClearRect
instance for the specified memory address.static VkClearRect.Buffer
create(long address, int capacity)
Create aVkClearRect.Buffer
instance at the specified memory.static VkClearRect
createSafe(long address)
static VkClearRect.Buffer
createSafe(long address, int capacity)
int
layerCount()
Returns the value of thelayerCount
field.VkClearRect
layerCount(int value)
Sets the specified value to thelayerCount
field.static VkClearRect
malloc()
Returns a newVkClearRect
instance allocated withmemAlloc
.static VkClearRect.Buffer
malloc(int capacity)
Returns a newVkClearRect.Buffer
instance allocated withmemAlloc
.static VkClearRect
mallocStack()
Returns a newVkClearRect
instance allocated on the thread-localMemoryStack
.static VkClearRect.Buffer
mallocStack(int capacity)
Returns a newVkClearRect.Buffer
instance allocated on the thread-localMemoryStack
.static VkClearRect.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect.Buffer
instance allocated on the specifiedMemoryStack
.static VkClearRect
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect
instance allocated on the specifiedMemoryStack
.static int
nbaseArrayLayer(long struct)
Unsafe version ofbaseArrayLayer()
.static void
nbaseArrayLayer(long struct, int value)
Unsafe version ofbaseArrayLayer
.static int
nlayerCount(long struct)
Unsafe version oflayerCount()
.static void
nlayerCount(long struct, int value)
Unsafe version oflayerCount
.static VkRect2D
nrect(long struct)
Unsafe version ofrect()
.static void
nrect(long struct, VkRect2D value)
Unsafe version ofrect
.VkRect2D
rect()
Returns aVkRect2D
view of therect
field.VkClearRect
rect(java.util.function.Consumer<VkRect2D> consumer)
Passes therect
field to the specifiedConsumer
.VkClearRect
rect(VkRect2D value)
Copies the specifiedVkRect2D
to therect
field.VkClearRect
set(VkClearRect src)
Copies the specified struct data to this struct.VkClearRect
set(VkRect2D rect, int baseArrayLayer, int layerCount)
Initializes this struct with the specified values.int
sizeof()
-
-
-
Constructor Detail
-
VkClearRect
public VkClearRect(java.nio.ByteBuffer container)
Creates aVkClearRect
instance at the current position of the specifiedByteBuffer
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 classorg.lwjgl.system.Struct
-
baseArrayLayer
public int baseArrayLayer()
Returns the value of thebaseArrayLayer
field.
-
layerCount
public int layerCount()
Returns the value of thelayerCount
field.
-
rect
public VkClearRect rect(VkRect2D value)
Copies the specifiedVkRect2D
to therect
field.
-
rect
public VkClearRect rect(java.util.function.Consumer<VkRect2D> consumer)
Passes therect
field to the specifiedConsumer
.
-
baseArrayLayer
public VkClearRect baseArrayLayer(int value)
Sets the specified value to thebaseArrayLayer
field.
-
layerCount
public VkClearRect layerCount(int value)
Sets the specified value to thelayerCount
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
-
malloc
public static VkClearRect malloc()
Returns a newVkClearRect
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static VkClearRect calloc()
Returns a newVkClearRect
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static VkClearRect create()
Returns a newVkClearRect
instance allocated withBufferUtils
.
-
create
public static VkClearRect create(long address)
Returns a newVkClearRect
instance for the specified memory address.
-
createSafe
@Nullable public static VkClearRect createSafe(long address)
-
malloc
public static VkClearRect.Buffer malloc(int capacity)
Returns a newVkClearRect.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static VkClearRect.Buffer calloc(int capacity)
Returns a newVkClearRect.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static VkClearRect.Buffer create(int capacity)
Returns a newVkClearRect.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static VkClearRect.Buffer create(long address, int capacity)
Create aVkClearRect.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static VkClearRect.Buffer createSafe(long address, int capacity)
-
mallocStack
public static VkClearRect mallocStack()
Returns a newVkClearRect
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static VkClearRect callocStack()
Returns a newVkClearRect
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static VkClearRect mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static VkClearRect callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static VkClearRect.Buffer mallocStack(int capacity)
Returns a newVkClearRect.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static VkClearRect.Buffer callocStack(int capacity)
Returns a newVkClearRect.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static VkClearRect.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static VkClearRect.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkClearRect.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
nbaseArrayLayer
public static int nbaseArrayLayer(long struct)
Unsafe version ofbaseArrayLayer()
.
-
nlayerCount
public static int nlayerCount(long struct)
Unsafe version oflayerCount()
.
-
nbaseArrayLayer
public static void nbaseArrayLayer(long struct, int value)
Unsafe version ofbaseArrayLayer
.
-
nlayerCount
public static void nlayerCount(long struct, int value)
Unsafe version oflayerCount
.
-
-