Package org.lwjgl.vulkan
Class VkPipelineRasterizationStateCreateInfo
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkPipelineRasterizationStateCreateInfo
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class VkPipelineRasterizationStateCreateInfo extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceStructure specifying parameters of a newly created pipeline rasterization state.Description
The application can also add a
VkPipelineRasterizationStateRasterizationOrderAMDstructure to thepNextchain of aVkPipelineRasterizationStateCreateInfostructure. This structure enables selecting the rasterization order to use when rendering with the corresponding graphics pipeline as described in Rasterization Order.Valid Usage
- If the depth clamping feature is not enabled,
depthClampEnablemust beFALSE - If the non-solid fill modes feature is not enabled,
polygonModemust bePOLYGON_MODE_FILLorPOLYGON_MODE_FILL_RECTANGLE_NV - If the
VK_NV_fill_rectangleextension is not enabled,polygonModemust not bePOLYGON_MODE_FILL_RECTANGLE_NV
Valid Usage (Implicit)
sTypemust beSTRUCTURE_TYPE_PIPELINE_RASTERIZATION_STATE_CREATE_INFO- Each
pNextmember of any structure (including this one) in thepNextchain must be eitherNULLor a pointer to a valid instance ofVkPipelineRasterizationConservativeStateCreateInfoEXT,VkPipelineRasterizationDepthClipStateCreateInfoEXT,VkPipelineRasterizationLineStateCreateInfoEXT,VkPipelineRasterizationStateRasterizationOrderAMD, orVkPipelineRasterizationStateStreamCreateInfoEXT - Each
sTypemember in thepNextchain must be unique flagsmust be 0polygonModemust be a validVkPolygonModevaluecullModemust be a valid combination ofVkCullModeFlagBitsvaluesfrontFacemust be a validVkFrontFacevalue
See Also
Member documentation
sType– the type of this structure.pNext–NULLor a pointer to an extension-specific structure.flags– reserved for future use.depthClampEnable– controls whether to clamp the fragment’s depth values as described in Depth Test. If the pipeline is not created withVkPipelineRasterizationDepthClipStateCreateInfoEXTpresent then enabling depth clamp will also disable clipping primitives to the z planes of the frustrum as described in Primitive Clipping. Otherwise depth clipping is controlled by the state set inVkPipelineRasterizationDepthClipStateCreateInfoEXT.rasterizerDiscardEnable– controls whether primitives are discarded immediately before the rasterization stage.polygonMode– the triangle rendering mode. SeeVkPolygonMode.cullMode– the triangle facing direction used for primitive culling. SeeVkCullModeFlagBits.frontFace– aVkFrontFacevalue specifying the front-facing triangle orientation to be used for culling.depthBiasEnable– controls whether to bias fragment depth values.depthBiasConstantFactor– a scalar factor controlling the constant depth value added to each fragment.depthBiasClamp– the maximum (or minimum) depth bias of a fragment.depthBiasSlopeFactor– a scalar factor applied to a fragment’s slope in depth bias calculations.lineWidth– the width of rasterized line segments.
Layout
struct VkPipelineRasterizationStateCreateInfo { VkStructureType sType; void const * pNext; VkPipelineRasterizationStateCreateFlags flags; VkBool32 depthClampEnable; VkBool32 rasterizerDiscardEnable; VkPolygonMode polygonMode; VkCullModeFlags cullMode; VkFrontFace frontFace; VkBool32 depthBiasEnable; float depthBiasConstantFactor; float depthBiasClamp; float depthBiasSlopeFactor; float lineWidth; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classVkPipelineRasterizationStateCreateInfo.BufferAn array ofVkPipelineRasterizationStateCreateInfostructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intCULLMODE
DEPTHBIASCLAMP
DEPTHBIASCONSTANTFACTOR
DEPTHBIASENABLE
DEPTHBIASSLOPEFACTOR
DEPTHCLAMPENABLE
FLAGS
FRONTFACE
LINEWIDTH
PNEXT
POLYGONMODE
RASTERIZERDISCARDENABLEThe struct member offsets.static intSIZEOFThe struct size in bytes.static intSTYPEThe struct member offsets.
-
Constructor Summary
Constructors Constructor Description VkPipelineRasterizationStateCreateInfo(java.nio.ByteBuffer container)Creates aVkPipelineRasterizationStateCreateInfoinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static VkPipelineRasterizationStateCreateInfocalloc()Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated withmemCalloc.static VkPipelineRasterizationStateCreateInfo.Buffercalloc(int capacity)Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated withmemCalloc.static VkPipelineRasterizationStateCreateInfocallocStack()Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static VkPipelineRasterizationStateCreateInfo.BuffercallocStack(int capacity)Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static VkPipelineRasterizationStateCreateInfo.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkPipelineRasterizationStateCreateInfocallocStack(org.lwjgl.system.MemoryStack stack)Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkPipelineRasterizationStateCreateInfocreate()Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated withBufferUtils.static VkPipelineRasterizationStateCreateInfo.Buffercreate(int capacity)Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated withBufferUtils.static VkPipelineRasterizationStateCreateInfocreate(long address)Returns a newVkPipelineRasterizationStateCreateInfoinstance for the specified memory address.static VkPipelineRasterizationStateCreateInfo.Buffercreate(long address, int capacity)Create aVkPipelineRasterizationStateCreateInfo.Bufferinstance at the specified memory.static VkPipelineRasterizationStateCreateInfocreateSafe(long address)static VkPipelineRasterizationStateCreateInfo.BuffercreateSafe(long address, int capacity)intcullMode()Returns the value of thecullModefield.VkPipelineRasterizationStateCreateInfocullMode(int value)Sets the specified value to thecullModefield.floatdepthBiasClamp()Returns the value of thedepthBiasClampfield.VkPipelineRasterizationStateCreateInfodepthBiasClamp(float value)Sets the specified value to thedepthBiasClampfield.floatdepthBiasConstantFactor()Returns the value of thedepthBiasConstantFactorfield.VkPipelineRasterizationStateCreateInfodepthBiasConstantFactor(float value)Sets the specified value to thedepthBiasConstantFactorfield.booleandepthBiasEnable()Returns the value of thedepthBiasEnablefield.VkPipelineRasterizationStateCreateInfodepthBiasEnable(boolean value)Sets the specified value to thedepthBiasEnablefield.floatdepthBiasSlopeFactor()Returns the value of thedepthBiasSlopeFactorfield.VkPipelineRasterizationStateCreateInfodepthBiasSlopeFactor(float value)Sets the specified value to thedepthBiasSlopeFactorfield.booleandepthClampEnable()Returns the value of thedepthClampEnablefield.VkPipelineRasterizationStateCreateInfodepthClampEnable(boolean value)Sets the specified value to thedepthClampEnablefield.intflags()Returns the value of theflagsfield.VkPipelineRasterizationStateCreateInfoflags(int value)Sets the specified value to theflagsfield.intfrontFace()Returns the value of thefrontFacefield.VkPipelineRasterizationStateCreateInfofrontFace(int value)Sets the specified value to thefrontFacefield.floatlineWidth()Returns the value of thelineWidthfield.VkPipelineRasterizationStateCreateInfolineWidth(float value)Sets the specified value to thelineWidthfield.static VkPipelineRasterizationStateCreateInfomalloc()Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated withmemAlloc.static VkPipelineRasterizationStateCreateInfo.Buffermalloc(int capacity)Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated withmemAlloc.static VkPipelineRasterizationStateCreateInfomallocStack()Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the thread-localMemoryStack.static VkPipelineRasterizationStateCreateInfo.BuffermallocStack(int capacity)Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the thread-localMemoryStack.static VkPipelineRasterizationStateCreateInfo.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the specifiedMemoryStack.static VkPipelineRasterizationStateCreateInfomallocStack(org.lwjgl.system.MemoryStack stack)Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the specifiedMemoryStack.static intncullMode(long struct)Unsafe version ofcullMode().static voidncullMode(long struct, int value)Unsafe version ofcullMode.static floatndepthBiasClamp(long struct)Unsafe version ofdepthBiasClamp().static voidndepthBiasClamp(long struct, float value)Unsafe version ofdepthBiasClamp.static floatndepthBiasConstantFactor(long struct)Unsafe version ofdepthBiasConstantFactor().static voidndepthBiasConstantFactor(long struct, float value)Unsafe version ofdepthBiasConstantFactor.static intndepthBiasEnable(long struct)Unsafe version ofdepthBiasEnable().static voidndepthBiasEnable(long struct, int value)Unsafe version ofdepthBiasEnable.static floatndepthBiasSlopeFactor(long struct)Unsafe version ofdepthBiasSlopeFactor().static voidndepthBiasSlopeFactor(long struct, float value)Unsafe version ofdepthBiasSlopeFactor.static intndepthClampEnable(long struct)Unsafe version ofdepthClampEnable().static voidndepthClampEnable(long struct, int value)Unsafe version ofdepthClampEnable.static intnflags(long struct)Unsafe version offlags().static voidnflags(long struct, int value)Unsafe version offlags.static intnfrontFace(long struct)Unsafe version offrontFace().static voidnfrontFace(long struct, int value)Unsafe version offrontFace.static floatnlineWidth(long struct)Unsafe version oflineWidth().static voidnlineWidth(long struct, float value)Unsafe version oflineWidth.static longnpNext(long struct)Unsafe version ofpNext().static voidnpNext(long struct, long value)Unsafe version ofpNext.static intnpolygonMode(long struct)Unsafe version ofpolygonMode().static voidnpolygonMode(long struct, int value)Unsafe version ofpolygonMode.static intnrasterizerDiscardEnable(long struct)Unsafe version ofrasterizerDiscardEnable().static voidnrasterizerDiscardEnable(long struct, int value)Unsafe version ofrasterizerDiscardEnable.static intnsType(long struct)Unsafe version ofsType().static voidnsType(long struct, int value)Unsafe version ofsType.longpNext()Returns the value of thepNextfield.VkPipelineRasterizationStateCreateInfopNext(long value)Sets the specified value to thepNextfield.intpolygonMode()Returns the value of thepolygonModefield.VkPipelineRasterizationStateCreateInfopolygonMode(int value)Sets the specified value to thepolygonModefield.booleanrasterizerDiscardEnable()Returns the value of therasterizerDiscardEnablefield.VkPipelineRasterizationStateCreateInforasterizerDiscardEnable(boolean value)Sets the specified value to therasterizerDiscardEnablefield.VkPipelineRasterizationStateCreateInfoset(int sType, long pNext, int flags, boolean depthClampEnable, boolean rasterizerDiscardEnable, int polygonMode, int cullMode, int frontFace, boolean depthBiasEnable, float depthBiasConstantFactor, float depthBiasClamp, float depthBiasSlopeFactor, float lineWidth)Initializes this struct with the specified values.VkPipelineRasterizationStateCreateInfoset(VkPipelineRasterizationStateCreateInfo src)Copies the specified struct data to this struct.intsizeof()intsType()Returns the value of thesTypefield.VkPipelineRasterizationStateCreateInfosType(int value)Sets the specified value to thesTypefield.
-
-
-
Constructor Detail
-
VkPipelineRasterizationStateCreateInfo
public VkPipelineRasterizationStateCreateInfo(java.nio.ByteBuffer container)
Creates aVkPipelineRasterizationStateCreateInfoinstance 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()
- Specified by:
sizeofin classorg.lwjgl.system.Struct
-
sType
public int sType()
Returns the value of thesTypefield.
-
pNext
public long pNext()
Returns the value of thepNextfield.
-
flags
public int flags()
Returns the value of theflagsfield.
-
depthClampEnable
public boolean depthClampEnable()
Returns the value of thedepthClampEnablefield.
-
rasterizerDiscardEnable
public boolean rasterizerDiscardEnable()
Returns the value of therasterizerDiscardEnablefield.
-
polygonMode
public int polygonMode()
Returns the value of thepolygonModefield.
-
cullMode
public int cullMode()
Returns the value of thecullModefield.
-
frontFace
public int frontFace()
Returns the value of thefrontFacefield.
-
depthBiasEnable
public boolean depthBiasEnable()
Returns the value of thedepthBiasEnablefield.
-
depthBiasConstantFactor
public float depthBiasConstantFactor()
Returns the value of thedepthBiasConstantFactorfield.
-
depthBiasClamp
public float depthBiasClamp()
Returns the value of thedepthBiasClampfield.
-
depthBiasSlopeFactor
public float depthBiasSlopeFactor()
Returns the value of thedepthBiasSlopeFactorfield.
-
lineWidth
public float lineWidth()
Returns the value of thelineWidthfield.
-
sType
public VkPipelineRasterizationStateCreateInfo sType(int value)
Sets the specified value to thesTypefield.
-
pNext
public VkPipelineRasterizationStateCreateInfo pNext(long value)
Sets the specified value to thepNextfield.
-
flags
public VkPipelineRasterizationStateCreateInfo flags(int value)
Sets the specified value to theflagsfield.
-
depthClampEnable
public VkPipelineRasterizationStateCreateInfo depthClampEnable(boolean value)
Sets the specified value to thedepthClampEnablefield.
-
rasterizerDiscardEnable
public VkPipelineRasterizationStateCreateInfo rasterizerDiscardEnable(boolean value)
Sets the specified value to therasterizerDiscardEnablefield.
-
polygonMode
public VkPipelineRasterizationStateCreateInfo polygonMode(int value)
Sets the specified value to thepolygonModefield.
-
cullMode
public VkPipelineRasterizationStateCreateInfo cullMode(int value)
Sets the specified value to thecullModefield.
-
frontFace
public VkPipelineRasterizationStateCreateInfo frontFace(int value)
Sets the specified value to thefrontFacefield.
-
depthBiasEnable
public VkPipelineRasterizationStateCreateInfo depthBiasEnable(boolean value)
Sets the specified value to thedepthBiasEnablefield.
-
depthBiasConstantFactor
public VkPipelineRasterizationStateCreateInfo depthBiasConstantFactor(float value)
Sets the specified value to thedepthBiasConstantFactorfield.
-
depthBiasClamp
public VkPipelineRasterizationStateCreateInfo depthBiasClamp(float value)
Sets the specified value to thedepthBiasClampfield.
-
depthBiasSlopeFactor
public VkPipelineRasterizationStateCreateInfo depthBiasSlopeFactor(float value)
Sets the specified value to thedepthBiasSlopeFactorfield.
-
lineWidth
public VkPipelineRasterizationStateCreateInfo lineWidth(float value)
Sets the specified value to thelineWidthfield.
-
set
public VkPipelineRasterizationStateCreateInfo set(int sType, long pNext, int flags, boolean depthClampEnable, boolean rasterizerDiscardEnable, int polygonMode, int cullMode, int frontFace, boolean depthBiasEnable, float depthBiasConstantFactor, float depthBiasClamp, float depthBiasSlopeFactor, float lineWidth)
Initializes this struct with the specified values.
-
set
public VkPipelineRasterizationStateCreateInfo set(VkPipelineRasterizationStateCreateInfo src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static VkPipelineRasterizationStateCreateInfo malloc()
Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static VkPipelineRasterizationStateCreateInfo calloc()
Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static VkPipelineRasterizationStateCreateInfo create()
Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated withBufferUtils.
-
create
public static VkPipelineRasterizationStateCreateInfo create(long address)
Returns a newVkPipelineRasterizationStateCreateInfoinstance for the specified memory address.
-
createSafe
@Nullable public static VkPipelineRasterizationStateCreateInfo createSafe(long address)
-
malloc
public static VkPipelineRasterizationStateCreateInfo.Buffer malloc(int capacity)
Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static VkPipelineRasterizationStateCreateInfo.Buffer calloc(int capacity)
Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static VkPipelineRasterizationStateCreateInfo.Buffer create(int capacity)
Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static VkPipelineRasterizationStateCreateInfo.Buffer create(long address, int capacity)
Create aVkPipelineRasterizationStateCreateInfo.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static VkPipelineRasterizationStateCreateInfo.Buffer createSafe(long address, int capacity)
-
mallocStack
public static VkPipelineRasterizationStateCreateInfo mallocStack()
Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the thread-localMemoryStack.
-
callocStack
public static VkPipelineRasterizationStateCreateInfo callocStack()
Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static VkPipelineRasterizationStateCreateInfo mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static VkPipelineRasterizationStateCreateInfo callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkPipelineRasterizationStateCreateInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static VkPipelineRasterizationStateCreateInfo.Buffer mallocStack(int capacity)
Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static VkPipelineRasterizationStateCreateInfo.Buffer callocStack(int capacity)
Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static VkPipelineRasterizationStateCreateInfo.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static VkPipelineRasterizationStateCreateInfo.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkPipelineRasterizationStateCreateInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nsType
public static int nsType(long struct)
Unsafe version ofsType().
-
npNext
public static long npNext(long struct)
Unsafe version ofpNext().
-
nflags
public static int nflags(long struct)
Unsafe version offlags().
-
ndepthClampEnable
public static int ndepthClampEnable(long struct)
Unsafe version ofdepthClampEnable().
-
nrasterizerDiscardEnable
public static int nrasterizerDiscardEnable(long struct)
Unsafe version ofrasterizerDiscardEnable().
-
npolygonMode
public static int npolygonMode(long struct)
Unsafe version ofpolygonMode().
-
ncullMode
public static int ncullMode(long struct)
Unsafe version ofcullMode().
-
nfrontFace
public static int nfrontFace(long struct)
Unsafe version offrontFace().
-
ndepthBiasEnable
public static int ndepthBiasEnable(long struct)
Unsafe version ofdepthBiasEnable().
-
ndepthBiasConstantFactor
public static float ndepthBiasConstantFactor(long struct)
Unsafe version ofdepthBiasConstantFactor().
-
ndepthBiasClamp
public static float ndepthBiasClamp(long struct)
Unsafe version ofdepthBiasClamp().
-
ndepthBiasSlopeFactor
public static float ndepthBiasSlopeFactor(long struct)
Unsafe version ofdepthBiasSlopeFactor().
-
nlineWidth
public static float nlineWidth(long struct)
Unsafe version oflineWidth().
-
nsType
public static void nsType(long struct, int value)Unsafe version ofsType.
-
npNext
public static void npNext(long struct, long value)Unsafe version ofpNext.
-
nflags
public static void nflags(long struct, int value)Unsafe version offlags.
-
ndepthClampEnable
public static void ndepthClampEnable(long struct, int value)Unsafe version ofdepthClampEnable.
-
nrasterizerDiscardEnable
public static void nrasterizerDiscardEnable(long struct, int value)Unsafe version ofrasterizerDiscardEnable.
-
npolygonMode
public static void npolygonMode(long struct, int value)Unsafe version ofpolygonMode.
-
ncullMode
public static void ncullMode(long struct, int value)Unsafe version ofcullMode.
-
nfrontFace
public static void nfrontFace(long struct, int value)Unsafe version offrontFace.
-
ndepthBiasEnable
public static void ndepthBiasEnable(long struct, int value)Unsafe version ofdepthBiasEnable.
-
ndepthBiasConstantFactor
public static void ndepthBiasConstantFactor(long struct, float value)Unsafe version ofdepthBiasConstantFactor.
-
ndepthBiasClamp
public static void ndepthBiasClamp(long struct, float value)Unsafe version ofdepthBiasClamp.
-
ndepthBiasSlopeFactor
public static void ndepthBiasSlopeFactor(long struct, float value)Unsafe version ofdepthBiasSlopeFactor.
-
nlineWidth
public static void nlineWidth(long struct, float value)Unsafe version oflineWidth.
-
-