Package org.lwjgl.vulkan
Class VkSpecializationInfo
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkSpecializationInfo
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class VkSpecializationInfo extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceStructure specifying specialization information.Valid Usage
- The
offsetmember of each element ofpMapEntriesmust be less thandataSize - The
sizemember of each element ofpMapEntriesmust be less than or equal todataSizeminusoffset - The
constantIDvalue of each element ofpMapEntriesmust be unique withinpMapEntries
Valid Usage (Implicit)
- If
mapEntryCountis not 0,pMapEntriesmust be a valid pointer to an array ofmapEntryCountvalidVkSpecializationMapEntrystructures - If
dataSizeis not 0,pDatamust be a valid pointer to an array ofdataSizebytes
See Also
VkPipelineShaderStageCreateInfo,VkSpecializationMapEntryLayout
struct VkSpecializationInfo { uint32_tmapEntryCount();VkSpecializationMapEntryconst *pMapEntries(); size_tdataSize(); void const *pData(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classVkSpecializationInfo.BufferAn array ofVkSpecializationInfostructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intDATASIZE
MAPENTRYCOUNT
PDATA
PMAPENTRIESThe struct member offsets.static intSIZEOFThe struct size in bytes.
-
Constructor Summary
Constructors Constructor Description VkSpecializationInfo(java.nio.ByteBuffer container)Creates aVkSpecializationInfoinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static VkSpecializationInfocalloc()Returns a newVkSpecializationInfoinstance allocated withmemCalloc.static VkSpecializationInfo.Buffercalloc(int capacity)Returns a newVkSpecializationInfo.Bufferinstance allocated withmemCalloc.static VkSpecializationInfo.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newVkSpecializationInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkSpecializationInfocalloc(org.lwjgl.system.MemoryStack stack)Returns a newVkSpecializationInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkSpecializationInfocallocStack()Deprecated.static VkSpecializationInfo.BuffercallocStack(int capacity)Deprecated.static VkSpecializationInfo.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static VkSpecializationInfocallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static VkSpecializationInfocreate()Returns a newVkSpecializationInfoinstance allocated withBufferUtils.static VkSpecializationInfo.Buffercreate(int capacity)Returns a newVkSpecializationInfo.Bufferinstance allocated withBufferUtils.static VkSpecializationInfocreate(long address)Returns a newVkSpecializationInfoinstance for the specified memory address.static VkSpecializationInfo.Buffercreate(long address, int capacity)Create aVkSpecializationInfo.Bufferinstance at the specified memory.static VkSpecializationInfocreateSafe(long address)static VkSpecializationInfo.BuffercreateSafe(long address, int capacity)longdataSize()the byte size of thepDatabuffer.static VkSpecializationInfomalloc()Returns a newVkSpecializationInfoinstance allocated withmemAlloc.static VkSpecializationInfo.Buffermalloc(int capacity)Returns a newVkSpecializationInfo.Bufferinstance allocated withmemAlloc.static VkSpecializationInfo.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newVkSpecializationInfo.Bufferinstance allocated on the specifiedMemoryStack.static VkSpecializationInfomalloc(org.lwjgl.system.MemoryStack stack)Returns a newVkSpecializationInfoinstance allocated on the specifiedMemoryStack.static VkSpecializationInfomallocStack()Deprecated.static VkSpecializationInfo.BuffermallocStack(int capacity)Deprecated.static VkSpecializationInfo.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static VkSpecializationInfomallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.intmapEntryCount()the number of entries in thepMapEntriesarray.static longndataSize(long struct)Unsafe version ofdataSize().static voidndataSize(long struct, long value)Sets the specified value to thedataSizefield of the specifiedstruct.static intnmapEntryCount(long struct)Unsafe version ofmapEntryCount().static voidnmapEntryCount(long struct, int value)Sets the specified value to themapEntryCountfield of the specifiedstruct.static java.nio.ByteBuffernpData(long struct)Unsafe version ofpData.static voidnpData(long struct, java.nio.ByteBuffer value)Unsafe version ofpData.static VkSpecializationMapEntry.BuffernpMapEntries(long struct)Unsafe version ofpMapEntries().static voidnpMapEntries(long struct, VkSpecializationMapEntry.Buffer value)Unsafe version ofpMapEntries.java.nio.ByteBufferpData()contains the actual constant values to specialize with.VkSpecializationInfopData(java.nio.ByteBuffer value)Sets the address of the specifiedByteBufferto thepData()field.VkSpecializationMapEntry.BufferpMapEntries()a pointer to an array ofVkSpecializationMapEntrystructures which map constant IDs to offsets inpData.VkSpecializationInfopMapEntries(VkSpecializationMapEntry.Buffer value)Sets the address of the specifiedVkSpecializationMapEntry.Bufferto thepMapEntries()field.VkSpecializationInfoset(VkSpecializationInfo src)Copies the specified struct data to this struct.VkSpecializationInfoset(VkSpecializationMapEntry.Buffer pMapEntries, java.nio.ByteBuffer pData)Initializes this struct with the specified values.intsizeof()static voidvalidate(long struct)Validates pointer members that should not beNULL.
-
-
-
Constructor Detail
-
VkSpecializationInfo
public VkSpecializationInfo(java.nio.ByteBuffer container)
Creates aVkSpecializationInfoinstance 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
-
mapEntryCount
public int mapEntryCount()
the number of entries in thepMapEntriesarray.
-
pMapEntries
@Nullable public VkSpecializationMapEntry.Buffer pMapEntries()
a pointer to an array ofVkSpecializationMapEntrystructures which map constant IDs to offsets inpData.
-
dataSize
public long dataSize()
the byte size of thepDatabuffer.
-
pData
@Nullable public java.nio.ByteBuffer pData()
contains the actual constant values to specialize with.
-
pMapEntries
public VkSpecializationInfo pMapEntries(@Nullable VkSpecializationMapEntry.Buffer value)
Sets the address of the specifiedVkSpecializationMapEntry.Bufferto thepMapEntries()field.
-
pData
public VkSpecializationInfo pData(@Nullable java.nio.ByteBuffer value)
Sets the address of the specifiedByteBufferto thepData()field.
-
set
public VkSpecializationInfo set(@Nullable VkSpecializationMapEntry.Buffer pMapEntries, @Nullable java.nio.ByteBuffer pData)
Initializes this struct with the specified values.
-
set
public VkSpecializationInfo set(VkSpecializationInfo src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static VkSpecializationInfo malloc()
Returns a newVkSpecializationInfoinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static VkSpecializationInfo calloc()
Returns a newVkSpecializationInfoinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static VkSpecializationInfo create()
Returns a newVkSpecializationInfoinstance allocated withBufferUtils.
-
create
public static VkSpecializationInfo create(long address)
Returns a newVkSpecializationInfoinstance for the specified memory address.
-
createSafe
@Nullable public static VkSpecializationInfo createSafe(long address)
-
malloc
public static VkSpecializationInfo.Buffer malloc(int capacity)
Returns a newVkSpecializationInfo.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static VkSpecializationInfo.Buffer calloc(int capacity)
Returns a newVkSpecializationInfo.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static VkSpecializationInfo.Buffer create(int capacity)
Returns a newVkSpecializationInfo.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static VkSpecializationInfo.Buffer create(long address, int capacity)
Create aVkSpecializationInfo.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static VkSpecializationInfo.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static VkSpecializationInfo mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static VkSpecializationInfo callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static VkSpecializationInfo mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static VkSpecializationInfo callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static VkSpecializationInfo.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static VkSpecializationInfo.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
mallocStack
@Deprecated public static VkSpecializationInfo.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static VkSpecializationInfo.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
malloc
public static VkSpecializationInfo malloc(org.lwjgl.system.MemoryStack stack)
Returns a newVkSpecializationInfoinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static VkSpecializationInfo calloc(org.lwjgl.system.MemoryStack stack)
Returns a newVkSpecializationInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static VkSpecializationInfo.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkSpecializationInfo.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static VkSpecializationInfo.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkSpecializationInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nmapEntryCount
public static int nmapEntryCount(long struct)
Unsafe version ofmapEntryCount().
-
npMapEntries
@Nullable public static VkSpecializationMapEntry.Buffer npMapEntries(long struct)
Unsafe version ofpMapEntries().
-
ndataSize
public static long ndataSize(long struct)
Unsafe version ofdataSize().
-
npData
@Nullable public static java.nio.ByteBuffer npData(long struct)
Unsafe version ofpData.
-
nmapEntryCount
public static void nmapEntryCount(long struct, int value)Sets the specified value to themapEntryCountfield of the specifiedstruct.
-
npMapEntries
public static void npMapEntries(long struct, @Nullable VkSpecializationMapEntry.Buffer value)Unsafe version ofpMapEntries.
-
ndataSize
public static void ndataSize(long struct, long value)Sets the specified value to thedataSizefield of the specifiedstruct.
-
npData
public static void npData(long struct, @Nullable java.nio.ByteBuffer value)Unsafe version ofpData.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL.- Parameters:
struct- the struct to validate
-
-