Package org.lwjgl.vulkan
Class VkStencilOpState
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkStencilOpState
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, NativeResource, Pointer
public class VkStencilOpState extends Struct
Khronos Reference Page
Vulkan SpecificationContains information about the stencil test as part of graphics pipeline creation.
Valid Usage
failOpmust be a validVkStencilOpvaluepassOpmust be a validVkStencilOpvaluedepthFailOpmust be a validVkStencilOpvaluecompareOpmust be a validVkCompareOpvalue
Member documentation
failOp– the action performed on samples that fail the stencil test. One of:STENCIL_OP_DECREMENT_AND_CLAMPSTENCIL_OP_DECREMENT_AND_WRAPSTENCIL_OP_INCREMENT_AND_CLAMPSTENCIL_OP_INCREMENT_AND_WRAPSTENCIL_OP_INVERTSTENCIL_OP_KEEPSTENCIL_OP_REPLACESTENCIL_OP_ZEROpassOp– the action performed on samples that pass both the depth and stencil testsdepthFailOp– the action performed on samples that pass the stencil test and fail the depth testcompareOp– the comparison operator used in the stencil test. One of:COMPARE_OP_ALWAYSCOMPARE_OP_EQUALCOMPARE_OP_GREATERCOMPARE_OP_GREATER_OR_EQUALCOMPARE_OP_LESSCOMPARE_OP_LESS_OR_EQUALCOMPARE_OP_NEVERCOMPARE_OP_NOT_EQUALcompareMask– selects the bits of the unsigned integer stencil values participating in the stencil testwriteMask– selects the bits of the unsigned integer stencil values updated by the stencil test in the stencil framebuffer attachmentreference– an integer reference value that is used in the unsigned stencil comparison
Layout
struct VkStencilOpState { VkStencilOp failOp; VkStencilOp passOp; VkStencilOp depthFailOp; VkCompareOp compareOp; uint32_t compareMask; uint32_t writeMask; uint32_t reference; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static classVkStencilOpState.BufferAn array ofVkStencilOpStatestructs.-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
Fields Modifier and Type Field and Description static intSIZEOFThe struct size in bytes.-
Fields inherited from interface org.lwjgl.system.Pointer
POINTER_SHIFT, POINTER_SIZE
-
-
Constructor Summary
Constructors Constructor and Description VkStencilOpState(java.nio.ByteBuffer container)Creates aVkStencilOpStateinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description static VkStencilOpStatecalloc()Returns a newVkStencilOpStateinstance allocated withmemCalloc.static VkStencilOpState.Buffercalloc(int capacity)Returns a newVkStencilOpState.Bufferinstance allocated withmemCalloc.static VkStencilOpStatecallocStack()Returns a newVkStencilOpStateinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static VkStencilOpState.BuffercallocStack(int capacity)Returns a newVkStencilOpState.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static VkStencilOpState.BuffercallocStack(int capacity, MemoryStack stack)Returns a newVkStencilOpState.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkStencilOpStatecallocStack(MemoryStack stack)Returns a newVkStencilOpStateinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.intcompareMask()Returns the value of thecompareMaskfield.VkStencilOpStatecompareMask(int value)Sets the specified value to thecompareMaskfield.intcompareOp()Returns the value of thecompareOpfield.VkStencilOpStatecompareOp(int value)Sets the specified value to thecompareOpfield.static VkStencilOpStatecreate()Returns a newVkStencilOpStateinstance allocated withBufferUtils.static VkStencilOpState.Buffercreate(int capacity)Returns a newVkStencilOpState.Bufferinstance allocated withBufferUtils.static VkStencilOpStatecreate(long address)Returns a newVkStencilOpStateinstance for the specified memory address ornullif the address isNULL.static VkStencilOpState.Buffercreate(long address, int capacity)Create aVkStencilOpState.Bufferinstance at the specified memory.intdepthFailOp()Returns the value of thedepthFailOpfield.VkStencilOpStatedepthFailOp(int value)Sets the specified value to thedepthFailOpfield.intfailOp()Returns the value of thefailOpfield.VkStencilOpStatefailOp(int value)Sets the specified value to thefailOpfield.static VkStencilOpStatemalloc()Returns a newVkStencilOpStateinstance allocated withmemAlloc.static VkStencilOpState.Buffermalloc(int capacity)Returns a newVkStencilOpState.Bufferinstance allocated withmemAlloc.static VkStencilOpStatemallocStack()Returns a newVkStencilOpStateinstance allocated on the thread-localMemoryStack.static VkStencilOpState.BuffermallocStack(int capacity)Returns a newVkStencilOpState.Bufferinstance allocated on the thread-localMemoryStack.static VkStencilOpState.BuffermallocStack(int capacity, MemoryStack stack)Returns a newVkStencilOpState.Bufferinstance allocated on the specifiedMemoryStack.static VkStencilOpStatemallocStack(MemoryStack stack)Returns a newVkStencilOpStateinstance allocated on the specifiedMemoryStack.VkStencilOpStatenset(long struct)Unsafe version ofset.intpassOp()Returns the value of thepassOpfield.VkStencilOpStatepassOp(int value)Sets the specified value to thepassOpfield.intreference()Returns the value of thereferencefield.VkStencilOpStatereference(int value)Sets the specified value to thereferencefield.VkStencilOpStateset(int failOp, int passOp, int depthFailOp, int compareOp, int compareMask, int writeMask, int reference)Initializes this struct with the specified values.VkStencilOpStateset(VkStencilOpState src)Copies the specified struct data to this struct.intsizeof()Returns thesizeof(struct).intwriteMask()Returns the value of thewriteMaskfield.VkStencilOpStatewriteMask(int value)Sets the specified value to thewriteMaskfield.-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
-
-
-
Constructor Detail
-
VkStencilOpState
public VkStencilOpState(java.nio.ByteBuffer container)
Creates aVkStencilOpStateinstance at the current position of the specifiedByteBuffercontainer. 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:StructReturns thesizeof(struct).
-
failOp
public int failOp()
Returns the value of thefailOpfield.
-
passOp
public int passOp()
Returns the value of thepassOpfield.
-
depthFailOp
public int depthFailOp()
Returns the value of thedepthFailOpfield.
-
compareOp
public int compareOp()
Returns the value of thecompareOpfield.
-
compareMask
public int compareMask()
Returns the value of thecompareMaskfield.
-
writeMask
public int writeMask()
Returns the value of thewriteMaskfield.
-
reference
public int reference()
Returns the value of thereferencefield.
-
failOp
public VkStencilOpState failOp(int value)
Sets the specified value to thefailOpfield.
-
passOp
public VkStencilOpState passOp(int value)
Sets the specified value to thepassOpfield.
-
depthFailOp
public VkStencilOpState depthFailOp(int value)
Sets the specified value to thedepthFailOpfield.
-
compareOp
public VkStencilOpState compareOp(int value)
Sets the specified value to thecompareOpfield.
-
compareMask
public VkStencilOpState compareMask(int value)
Sets the specified value to thecompareMaskfield.
-
writeMask
public VkStencilOpState writeMask(int value)
Sets the specified value to thewriteMaskfield.
-
reference
public VkStencilOpState reference(int value)
Sets the specified value to thereferencefield.
-
set
public VkStencilOpState set(int failOp, int passOp, int depthFailOp, int compareOp, int compareMask, int writeMask, int reference)
Initializes this struct with the specified values.
-
nset
public VkStencilOpState nset(long struct)
Unsafe version ofset.
-
set
public VkStencilOpState set(VkStencilOpState src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static VkStencilOpState malloc()
Returns a newVkStencilOpStateinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static VkStencilOpState calloc()
Returns a newVkStencilOpStateinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static VkStencilOpState create()
Returns a newVkStencilOpStateinstance allocated withBufferUtils.
-
create
public static VkStencilOpState create(long address)
Returns a newVkStencilOpStateinstance for the specified memory address ornullif the address isNULL.
-
malloc
public static VkStencilOpState.Buffer malloc(int capacity)
Returns a newVkStencilOpState.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static VkStencilOpState.Buffer calloc(int capacity)
Returns a newVkStencilOpState.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static VkStencilOpState.Buffer create(int capacity)
Returns a newVkStencilOpState.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static VkStencilOpState.Buffer create(long address, int capacity)
Create aVkStencilOpState.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
mallocStack
public static VkStencilOpState mallocStack()
Returns a newVkStencilOpStateinstance allocated on the thread-localMemoryStack.
-
callocStack
public static VkStencilOpState callocStack()
Returns a newVkStencilOpStateinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static VkStencilOpState mallocStack(MemoryStack stack)
Returns a newVkStencilOpStateinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static VkStencilOpState callocStack(MemoryStack stack)
Returns a newVkStencilOpStateinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static VkStencilOpState.Buffer mallocStack(int capacity)
Returns a newVkStencilOpState.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static VkStencilOpState.Buffer callocStack(int capacity)
Returns a newVkStencilOpState.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static VkStencilOpState.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newVkStencilOpState.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static VkStencilOpState.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newVkStencilOpState.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
-