Package org.lwjgl.vulkan
Class VkClearDepthStencilValue
- All Implemented Interfaces:
AutoCloseable
,NativeResource
,Pointer
public class VkClearDepthStencilValue
extends Struct<VkClearDepthStencilValue>
implements NativeResource
Structure specifying a clear depth stencil value.
Valid Usage
- Unless the
VK_EXT_depth_range_unrestricted
extension is enableddepth
must be between0.0
and1.0
, inclusive
See Also
VkClearValue
, CmdClearDepthStencilImage
Layout
struct VkClearDepthStencilValue {
float depth()
;
uint32_t stencil()
;
}
-
Nested Class Summary
Nested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidation
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
The struct alignment in bytes.static final int
The struct member offsets.static final int
The struct size in bytes.static final int
The struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorDescriptionVkClearDepthStencilValue
(ByteBuffer container) Creates aVkClearDepthStencilValue
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionstatic VkClearDepthStencilValue
calloc()
Returns a newVkClearDepthStencilValue
instance allocated withmemCalloc
.calloc
(int capacity) Returns a newVkClearDepthStencilValue.Buffer
instance allocated withmemCalloc
.calloc
(int capacity, MemoryStack stack) Returns a newVkClearDepthStencilValue.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkClearDepthStencilValue
calloc
(MemoryStack stack) Returns a newVkClearDepthStencilValue
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkClearDepthStencilValue
Deprecated.callocStack
(int capacity) Deprecated.callocStack
(int capacity, MemoryStack stack) Deprecated.static VkClearDepthStencilValue
callocStack
(MemoryStack stack) Deprecated.static VkClearDepthStencilValue
create()
Returns a newVkClearDepthStencilValue
instance allocated withBufferUtils
.create
(int capacity) Returns a newVkClearDepthStencilValue.Buffer
instance allocated withBufferUtils
.static VkClearDepthStencilValue
create
(long address) Returns a newVkClearDepthStencilValue
instance for the specified memory address.create
(long address, int capacity) Create aVkClearDepthStencilValue.Buffer
instance at the specified memory.static VkClearDepthStencilValue
createSafe
(long address) createSafe
(long address, int capacity) float
depth()
the clear value for the depth aspect of the depth/stencil attachment.depth
(float value) Sets the specified value to thedepth()
field.static VkClearDepthStencilValue
malloc()
Returns a newVkClearDepthStencilValue
instance allocated withmemAlloc
.malloc
(int capacity) Returns a newVkClearDepthStencilValue.Buffer
instance allocated withmemAlloc
.malloc
(int capacity, MemoryStack stack) Returns a newVkClearDepthStencilValue.Buffer
instance allocated on the specifiedMemoryStack
.static VkClearDepthStencilValue
malloc
(MemoryStack stack) Returns a newVkClearDepthStencilValue
instance allocated on the specifiedMemoryStack
.static VkClearDepthStencilValue
Deprecated.mallocStack
(int capacity) Deprecated.mallocStack
(int capacity, MemoryStack stack) Deprecated.static VkClearDepthStencilValue
mallocStack
(MemoryStack stack) Deprecated.static float
ndepth
(long struct) Unsafe version ofdepth()
.static void
ndepth
(long struct, float value) Unsafe version ofdepth
.static int
nstencil
(long struct) Unsafe version ofstencil()
.static void
nstencil
(long struct, int value) Unsafe version ofstencil
.set
(float depth, int stencil) Initializes this struct with the specified values.Copies the specified struct data to this struct.int
sizeof()
Returnssizeof(struct)
.int
stencil()
the clear value for the stencil aspect of the depth/stencil attachment.stencil
(int value) Sets the specified value to thestencil()
field.Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
Methods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
DEPTH
public static final int DEPTHThe struct member offsets. -
STENCIL
public static final int STENCILThe struct member offsets.
-
-
Constructor Details
-
VkClearDepthStencilValue
Creates aVkClearDepthStencilValue
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 Details
-
sizeof
public int sizeof()Description copied from class:Struct
Returnssizeof(struct)
.- Specified by:
sizeof
in classStruct<VkClearDepthStencilValue>
-
depth
public float depth()the clear value for the depth aspect of the depth/stencil attachment. It is a floating-point value which is automatically converted to the attachment’s format. -
stencil
public int stencil()the clear value for the stencil aspect of the depth/stencil attachment. It is a 32-bit integer value which is converted to the attachment’s format by taking the appropriate number of LSBs. -
depth
Sets the specified value to thedepth()
field. -
stencil
Sets the specified value to thestencil()
field. -
set
Initializes this struct with the specified values. -
set
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
Returns a newVkClearDepthStencilValue
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newVkClearDepthStencilValue
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newVkClearDepthStencilValue
instance allocated withBufferUtils
. -
create
Returns a newVkClearDepthStencilValue
instance for the specified memory address. -
createSafe
-
malloc
Returns a newVkClearDepthStencilValue.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
Returns a newVkClearDepthStencilValue.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
Returns a newVkClearDepthStencilValue.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
Create aVkClearDepthStencilValue.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
-
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
mallocStack
@Deprecated public static VkClearDepthStencilValue.Buffer mallocStack(int capacity, MemoryStack stack) Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
@Deprecated public static VkClearDepthStencilValue.Buffer callocStack(int capacity, MemoryStack stack) Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
malloc
Returns a newVkClearDepthStencilValue
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newVkClearDepthStencilValue
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
Returns a newVkClearDepthStencilValue.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
calloc
Returns a newVkClearDepthStencilValue.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
ndepth
public static float ndepth(long struct) Unsafe version ofdepth()
. -
nstencil
public static int nstencil(long struct) Unsafe version ofstencil()
. -
ndepth
public static void ndepth(long struct, float value) Unsafe version ofdepth
. -
nstencil
public static void nstencil(long struct, int value) Unsafe version ofstencil
.
-