Package org.lwjgl.vulkan
Class VkPresentInfoKHR
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkPresentInfoKHR
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, NativeResource, Pointer
public class VkPresentInfoKHR extends Struct
Khronos Reference Page
Vulkan SpecificationSpecifies the parameters of an image presentation.
Valid Usage
sType
must beSTRUCTURE_TYPE_PRESENT_INFO_KHR
pNext
must beNULL
- If
waitSemaphoreCount
is not 0, andpWaitSemaphores
is notNULL
,pWaitSemaphores
must be a pointer to an array ofwaitSemaphoreCount
validVkSemaphore
handles pSwapchains
must be a pointer to an array ofswapchainCount
validVkSwapchainKHR
handlespImageIndices
must be a pointer to an array ofswapchainCount
uint32_t
values- If
pResults
is notNULL
,pResults
must be a pointer to an array ofswapchainCount
VkResult
values swapchainCount
must be greater than 0- Each of the elements of
pSwapchains
and the elements ofpWaitSemaphores
that are valid handles must have been created, allocated or retrieved from the sameVkInstance
- Any given element of
pImageIndices
must be the index of a presentable image acquired from the swapchain specified by the corresponding element of thepSwapchains
array - Any given element of
VkSemaphore
inpWaitSemaphores
must refer to a prior signal of thatVkSemaphore
that won't be consumed by any other wait on that semaphore
Member documentation
sType
– the type of this structure. Must be:STRUCTURE_TYPE_PRESENT_INFO_KHR
pNext
– reserved for use by extensionswaitSemaphoreCount
– the number of semaphores to wait for before issuing the present request. The number may be zero.pWaitSemaphores
– if non-NULL
, is an array ofVkSemaphore
objects withwaitSemaphoreCount
entries, and specifies the semaphores to wait for before issuing the present requestswapchainCount
– the number of swapchains being presented to by this commandpSwapchains
– an array ofVkSwapchainKHR
objects withswapchainCount
entries. A given swapchain must not appear in this list more than once.pImageIndices
– an array of indices into the array of each swapchain’s presentable images, withswapchainCount
entries. Each entry in this array identifies the image to present on the corresponding entry in thepSwapchains
array.pResults
– an array ofVkResult
typed elements withswapchainCount
entries. Applications that don’t need per-swapchain results can useNULL
forpResults
. If non-NULL
, each entry inpResults
will be set to theVkResult
for presenting the swapchain corresponding to the same index inpSwapchains
.
Layout
struct VkPresentInfoKHR { VkStructureType sType; const void * pNext; uint32_t waitSemaphoreCount; const VkSemaphore * pWaitSemaphores; uint32_t swapchainCount; const VkSwapchainKHR * pSwapchains; const uint32_t * pImageIndices; VkResult * pResults; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static class
VkPresentInfoKHR.Buffer
An array ofVkPresentInfoKHR
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 VkPresentInfoKHR(java.nio.ByteBuffer container)
Creates aVkPresentInfoKHR
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 static VkPresentInfoKHR
calloc()
Returns a newVkPresentInfoKHR
instance allocated withmemCalloc
.static VkPresentInfoKHR.Buffer
calloc(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated withmemCalloc
.static VkPresentInfoKHR
callocStack()
Returns a newVkPresentInfoKHR
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkPresentInfoKHR.Buffer
callocStack(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkPresentInfoKHR.Buffer
callocStack(int capacity, MemoryStack stack)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkPresentInfoKHR
callocStack(MemoryStack stack)
Returns a newVkPresentInfoKHR
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkPresentInfoKHR
create()
Returns a newVkPresentInfoKHR
instance allocated withBufferUtils
.static VkPresentInfoKHR.Buffer
create(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated withBufferUtils
.static VkPresentInfoKHR
create(long address)
Returns a newVkPresentInfoKHR
instance for the specified memory address ornull
if the address isNULL
.static VkPresentInfoKHR.Buffer
create(long address, int capacity)
Create aVkPresentInfoKHR.Buffer
instance at the specified memory.static VkPresentInfoKHR
malloc()
Returns a newVkPresentInfoKHR
instance allocated withmemAlloc
.static VkPresentInfoKHR.Buffer
malloc(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated withmemAlloc
.static VkPresentInfoKHR
mallocStack()
Returns a newVkPresentInfoKHR
instance allocated on the thread-localMemoryStack
.static VkPresentInfoKHR.Buffer
mallocStack(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the thread-localMemoryStack
.static VkPresentInfoKHR.Buffer
mallocStack(int capacity, MemoryStack stack)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the specifiedMemoryStack
.static VkPresentInfoKHR
mallocStack(MemoryStack stack)
Returns a newVkPresentInfoKHR
instance allocated on the specifiedMemoryStack
.VkPresentInfoKHR
nset(long struct)
Unsafe version ofset
.java.nio.IntBuffer
pImageIndices()
Returns aIntBuffer
view of the data pointed to by thepImageIndices
field.VkPresentInfoKHR
pImageIndices(java.nio.IntBuffer value)
Sets the address of the specifiedIntBuffer
to thepImageIndices
field.long
pNext()
Returns the value of thepNext
field.VkPresentInfoKHR
pNext(long value)
Sets the specified value to thepNext
field.java.nio.IntBuffer
pResults()
Returns aIntBuffer
view of the data pointed to by thepResults
field.VkPresentInfoKHR
pResults(java.nio.IntBuffer value)
Sets the address of the specifiedIntBuffer
to thepResults
field.java.nio.LongBuffer
pSwapchains()
Returns aLongBuffer
view of the data pointed to by thepSwapchains
field.VkPresentInfoKHR
pSwapchains(java.nio.LongBuffer value)
Sets the address of the specifiedLongBuffer
to thepSwapchains
field.java.nio.LongBuffer
pWaitSemaphores()
Returns aLongBuffer
view of the data pointed to by thepWaitSemaphores
field.VkPresentInfoKHR
pWaitSemaphores(java.nio.LongBuffer value)
Sets the address of the specifiedLongBuffer
to thepWaitSemaphores
field.VkPresentInfoKHR
set(int sType, long pNext, java.nio.LongBuffer pWaitSemaphores, int swapchainCount, java.nio.LongBuffer pSwapchains, java.nio.IntBuffer pImageIndices, java.nio.IntBuffer pResults)
Initializes this struct with the specified values.VkPresentInfoKHR
set(VkPresentInfoKHR src)
Copies the specified struct data to this struct.int
sizeof()
Returns thesizeof(struct)
.int
sType()
Returns the value of thesType
field.VkPresentInfoKHR
sType(int value)
Sets the specified value to thesType
field.int
swapchainCount()
Returns the value of theswapchainCount
field.VkPresentInfoKHR
swapchainCount(int value)
Sets the specified value to theswapchainCount
field.static void
validate(long struct)
Validates pointer members that should not beNULL
.static void
validate(long array, int count)
CallsVkPresentInfoKHR.validate(long)
for each struct contained in the specified struct array.int
waitSemaphoreCount()
Returns the value of thewaitSemaphoreCount
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
-
VkPresentInfoKHR
public VkPresentInfoKHR(java.nio.ByteBuffer container)
Creates aVkPresentInfoKHR
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)
.
-
sType
public int sType()
Returns the value of thesType
field.
-
pNext
public long pNext()
Returns the value of thepNext
field.
-
waitSemaphoreCount
public int waitSemaphoreCount()
Returns the value of thewaitSemaphoreCount
field.
-
pWaitSemaphores
public java.nio.LongBuffer pWaitSemaphores()
Returns aLongBuffer
view of the data pointed to by thepWaitSemaphores
field.
-
swapchainCount
public int swapchainCount()
Returns the value of theswapchainCount
field.
-
pSwapchains
public java.nio.LongBuffer pSwapchains()
Returns aLongBuffer
view of the data pointed to by thepSwapchains
field.
-
pImageIndices
public java.nio.IntBuffer pImageIndices()
Returns aIntBuffer
view of the data pointed to by thepImageIndices
field.
-
pResults
public java.nio.IntBuffer pResults()
Returns aIntBuffer
view of the data pointed to by thepResults
field.
-
sType
public VkPresentInfoKHR sType(int value)
Sets the specified value to thesType
field.
-
pNext
public VkPresentInfoKHR pNext(long value)
Sets the specified value to thepNext
field.
-
pWaitSemaphores
public VkPresentInfoKHR pWaitSemaphores(java.nio.LongBuffer value)
Sets the address of the specifiedLongBuffer
to thepWaitSemaphores
field.
-
swapchainCount
public VkPresentInfoKHR swapchainCount(int value)
Sets the specified value to theswapchainCount
field.
-
pSwapchains
public VkPresentInfoKHR pSwapchains(java.nio.LongBuffer value)
Sets the address of the specifiedLongBuffer
to thepSwapchains
field.
-
pImageIndices
public VkPresentInfoKHR pImageIndices(java.nio.IntBuffer value)
Sets the address of the specifiedIntBuffer
to thepImageIndices
field.
-
pResults
public VkPresentInfoKHR pResults(java.nio.IntBuffer value)
Sets the address of the specifiedIntBuffer
to thepResults
field.
-
set
public VkPresentInfoKHR set(int sType, long pNext, java.nio.LongBuffer pWaitSemaphores, int swapchainCount, java.nio.LongBuffer pSwapchains, java.nio.IntBuffer pImageIndices, java.nio.IntBuffer pResults)
Initializes this struct with the specified values.
-
nset
public VkPresentInfoKHR nset(long struct)
Unsafe version ofset
.
-
set
public VkPresentInfoKHR set(VkPresentInfoKHR src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static VkPresentInfoKHR malloc()
Returns a newVkPresentInfoKHR
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static VkPresentInfoKHR calloc()
Returns a newVkPresentInfoKHR
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static VkPresentInfoKHR create()
Returns a newVkPresentInfoKHR
instance allocated withBufferUtils
.
-
create
public static VkPresentInfoKHR create(long address)
Returns a newVkPresentInfoKHR
instance for the specified memory address ornull
if the address isNULL
.
-
malloc
public static VkPresentInfoKHR.Buffer malloc(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static VkPresentInfoKHR.Buffer calloc(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static VkPresentInfoKHR.Buffer create(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static VkPresentInfoKHR.Buffer create(long address, int capacity)
Create aVkPresentInfoKHR.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
mallocStack
public static VkPresentInfoKHR mallocStack()
Returns a newVkPresentInfoKHR
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static VkPresentInfoKHR callocStack()
Returns a newVkPresentInfoKHR
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static VkPresentInfoKHR mallocStack(MemoryStack stack)
Returns a newVkPresentInfoKHR
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static VkPresentInfoKHR callocStack(MemoryStack stack)
Returns a newVkPresentInfoKHR
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static VkPresentInfoKHR.Buffer mallocStack(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static VkPresentInfoKHR.Buffer callocStack(int capacity)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static VkPresentInfoKHR.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static VkPresentInfoKHR.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newVkPresentInfoKHR.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-
validate
public static void validate(long array, int count)
CallsVkPresentInfoKHR.validate(long)
for each struct contained in the specified struct array.- Parameters:
array
- the struct array to validatecount
- the number of structs inarray
-
-