Package org.lwjgl.vulkan
Class VkVertexInputBindingDescription
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkVertexInputBindingDescription
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, NativeResource, Pointer
public class VkVertexInputBindingDescription extends Struct
Khronos Reference Page
Vulkan SpecificationDescribes a vertex input binding.
Valid Usage
inputRate
must be a validVkVertexInputRate
valuebinding
must be less thanVkPhysicalDeviceLimits
::maxVertexInputBindings
stride
must be less than or equal toVkPhysicalDeviceLimits
::maxVertexInputBindingStride
Member documentation
binding
– the binding number that this structure describesstride
– the distance in bytes between two consecutive elements within the bufferinputRate
– aVkVertexInputRate
value that specifies whether vertex attribute addressing is a function of the vertex index or of the instance index. One of:VERTEX_INPUT_RATE_INSTANCE
VERTEX_INPUT_RATE_VERTEX
Layout
struct VkVertexInputBindingDescription { uint32_t binding; uint32_t stride; VkVertexInputRate inputRate; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static class
VkVertexInputBindingDescription.Buffer
An array ofVkVertexInputBindingDescription
structs.-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
Fields Modifier and Type Field and Description static int
SIZEOF
The struct size in bytes.-
Fields inherited from interface org.lwjgl.system.Pointer
POINTER_SHIFT, POINTER_SIZE
-
-
Constructor Summary
Constructors Constructor and Description VkVertexInputBindingDescription(java.nio.ByteBuffer container)
Creates aVkVertexInputBindingDescription
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description int
binding()
Returns the value of thebinding
field.VkVertexInputBindingDescription
binding(int value)
Sets the specified value to thebinding
field.static VkVertexInputBindingDescription
calloc()
Returns a newVkVertexInputBindingDescription
instance allocated withmemCalloc
.static VkVertexInputBindingDescription.Buffer
calloc(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated withmemCalloc
.static VkVertexInputBindingDescription
callocStack()
Returns a newVkVertexInputBindingDescription
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkVertexInputBindingDescription.Buffer
callocStack(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkVertexInputBindingDescription.Buffer
callocStack(int capacity, MemoryStack stack)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkVertexInputBindingDescription
callocStack(MemoryStack stack)
Returns a newVkVertexInputBindingDescription
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkVertexInputBindingDescription
create()
Returns a newVkVertexInputBindingDescription
instance allocated withBufferUtils
.static VkVertexInputBindingDescription.Buffer
create(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated withBufferUtils
.static VkVertexInputBindingDescription
create(long address)
Returns a newVkVertexInputBindingDescription
instance for the specified memory address ornull
if the address isNULL
.static VkVertexInputBindingDescription.Buffer
create(long address, int capacity)
Create aVkVertexInputBindingDescription.Buffer
instance at the specified memory.int
inputRate()
Returns the value of theinputRate
field.VkVertexInputBindingDescription
inputRate(int value)
Sets the specified value to theinputRate
field.static VkVertexInputBindingDescription
malloc()
Returns a newVkVertexInputBindingDescription
instance allocated withmemAlloc
.static VkVertexInputBindingDescription.Buffer
malloc(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated withmemAlloc
.static VkVertexInputBindingDescription
mallocStack()
Returns a newVkVertexInputBindingDescription
instance allocated on the thread-localMemoryStack
.static VkVertexInputBindingDescription.Buffer
mallocStack(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the thread-localMemoryStack
.static VkVertexInputBindingDescription.Buffer
mallocStack(int capacity, MemoryStack stack)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the specifiedMemoryStack
.static VkVertexInputBindingDescription
mallocStack(MemoryStack stack)
Returns a newVkVertexInputBindingDescription
instance allocated on the specifiedMemoryStack
.VkVertexInputBindingDescription
nset(long struct)
Unsafe version ofset
.VkVertexInputBindingDescription
set(int binding, int stride, int inputRate)
Initializes this struct with the specified values.VkVertexInputBindingDescription
set(VkVertexInputBindingDescription src)
Copies the specified struct data to this struct.int
sizeof()
Returns thesizeof(struct)
.int
stride()
Returns the value of thestride
field.VkVertexInputBindingDescription
stride(int value)
Sets the specified value to thestride
field.-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
-
-
-
Constructor Detail
-
VkVertexInputBindingDescription
public VkVertexInputBindingDescription(java.nio.ByteBuffer container)
Creates aVkVertexInputBindingDescription
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()
Description copied from class:Struct
Returns thesizeof(struct)
.
-
binding
public int binding()
Returns the value of thebinding
field.
-
stride
public int stride()
Returns the value of thestride
field.
-
inputRate
public int inputRate()
Returns the value of theinputRate
field.
-
binding
public VkVertexInputBindingDescription binding(int value)
Sets the specified value to thebinding
field.
-
stride
public VkVertexInputBindingDescription stride(int value)
Sets the specified value to thestride
field.
-
inputRate
public VkVertexInputBindingDescription inputRate(int value)
Sets the specified value to theinputRate
field.
-
set
public VkVertexInputBindingDescription set(int binding, int stride, int inputRate)
Initializes this struct with the specified values.
-
nset
public VkVertexInputBindingDescription nset(long struct)
Unsafe version ofset
.
-
set
public VkVertexInputBindingDescription set(VkVertexInputBindingDescription src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static VkVertexInputBindingDescription malloc()
Returns a newVkVertexInputBindingDescription
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static VkVertexInputBindingDescription calloc()
Returns a newVkVertexInputBindingDescription
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static VkVertexInputBindingDescription create()
Returns a newVkVertexInputBindingDescription
instance allocated withBufferUtils
.
-
create
public static VkVertexInputBindingDescription create(long address)
Returns a newVkVertexInputBindingDescription
instance for the specified memory address ornull
if the address isNULL
.
-
malloc
public static VkVertexInputBindingDescription.Buffer malloc(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static VkVertexInputBindingDescription.Buffer calloc(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static VkVertexInputBindingDescription.Buffer create(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static VkVertexInputBindingDescription.Buffer create(long address, int capacity)
Create aVkVertexInputBindingDescription.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
mallocStack
public static VkVertexInputBindingDescription mallocStack()
Returns a newVkVertexInputBindingDescription
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static VkVertexInputBindingDescription callocStack()
Returns a newVkVertexInputBindingDescription
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static VkVertexInputBindingDescription mallocStack(MemoryStack stack)
Returns a newVkVertexInputBindingDescription
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static VkVertexInputBindingDescription callocStack(MemoryStack stack)
Returns a newVkVertexInputBindingDescription
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static VkVertexInputBindingDescription.Buffer mallocStack(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static VkVertexInputBindingDescription.Buffer callocStack(int capacity)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static VkVertexInputBindingDescription.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static VkVertexInputBindingDescription.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newVkVertexInputBindingDescription.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
-