Top Description Inners Fields Constructors Methods
org.lwjgl.vulkan

public Class VkApplicationInfo

extends Struct<VkApplicationInfo>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable
Imports
javax.annotation.*, java.nio.*, org.lwjgl.*, org.lwjgl.system.*

Structure specifying application information.
Description

Vulkan 1.0 implementations were required to return ERROR_INCOMPATIBLE_DRIVER if apiVersion was larger than 1.0. Implementations that support Vulkan 1.1 or later must not return ERROR_INCOMPATIBLE_DRIVER for any value of apiVersion .

Note

Because Vulkan 1.0 implementations may fail with ERROR_INCOMPATIBLE_DRIVER, applications should determine the version of Vulkan available before calling CreateInstance. If the GetInstanceProcAddr returns NULL for EnumerateInstanceVersion, it is a Vulkan 1.0 implementation. Otherwise, the application can call EnumerateInstanceVersion to determine the version of Vulkan.

As long as the instance supports at least Vulkan 1.1, an application can use different versions of Vulkan with an instance than it does with a device or physical device.

Note

The Khronos validation layers will treat apiVersion as the highest API version the application targets, and will validate API usage against the minimum of that version and the implementation version (instance or device, depending on context). If an application tries to use functionality from a greater version than this, a validation error will be triggered.

For example, if the instance supports Vulkan 1.1 and three physical devices support Vulkan 1.0, Vulkan 1.1, and Vulkan 1.2, respectively, and if the application sets apiVersion to 1.2, the application can use the following versions of Vulkan:

If we modify the above example so that the application sets apiVersion to 1.1, then the application must not use Vulkan 1.2 functionality on the physical device that supports Vulkan 1.2.

Note

Providing a NULL VkInstanceCreateInfo::pApplicationInfo or providing an apiVersion of 0 is equivalent to providing an apiVersion of VK_MAKE_API_VERSION(0,1,0,0).

Valid Usage
Valid Usage (Implicit)
See Also

VkInstanceCreateInfo

Layout


struct VkApplicationInfo {
    VkStructureType sType;
    void const * pNext;
    char const * pApplicationName;
    uint32_t applicationVersion;
    char const * pEngineName;
    uint32_t engineVersion;
    uint32_t apiVersion;
}

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
public static final int
ALIGNOF

The struct alignment in bytes.

public static final int
APIVERSION

The struct member offsets.

public static final int
APPLICATIONVERSION

The struct member offsets.

public static final int
ENGINEVERSION

The struct member offsets.

public static final int
PAPPLICATIONNAME

The struct member offsets.

public static final int
PENGINENAME

The struct member offsets.

public static final int
PNEXT

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

public static final int
STYPE

The struct member offsets.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

AccessConstructor and Description
protected
VkApplicationInfo(long address, ByteBuffer container)

public
VkApplicationInfo(ByteBuffer container)

Creates a VkApplicationInfo instance at the current position of the specified ByteBuffer container.

Method Summary

Modifier and TypeMethod and Description
public int
apiVersion()

must be the highest version of Vulkan that the application is designed to use, encoded as described in Version Numbers.

public VkApplicationInfo
apiVersion(int value)

Sets the specified value to the apiVersion field.

public int
applicationVersion()

an unsigned integer variable containing the developer-supplied version number of the application.

public VkApplicationInfo
applicationVersion(int value)

Sets the specified value to the applicationVersion field.

public static VkApplicationInfo
calloc()

Returns a new VkApplicationInfo instance allocated with memCalloc.

public static VkApplicationInfo.Buffer
calloc(int
the buffer capacity
capacity
)

Returns a new VkApplicationInfo.Buffer instance allocated with memCalloc.

public static VkApplicationInfo
calloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new VkApplicationInfo instance allocated on the specified MemoryStack and initializes all its bits to zero.

public static VkApplicationInfo.Buffer
calloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new VkApplicationInfo.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.

public static VkApplicationInfo
callocStack()

Deprecated
Deprecated for removal in 3.4.0.
public static VkApplicationInfo
callocStack(MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
public static VkApplicationInfo.Buffer
callocStack(int capacity)

Deprecated
Deprecated for removal in 3.4.0.
public static VkApplicationInfo.Buffer
callocStack(int capacity, MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
protected VkApplicationInfo
create(long
the struct memory address
address
,
ByteBuffer
an optional container buffer, to be referenced strongly by the struct instance.
container
)

Implements abstract org.lwjgl.system.Struct.create.

Similar to the constructor, but returns the exact type of the Struct subclass.
public static VkApplicationInfo
create()

Returns a new VkApplicationInfo instance allocated with BufferUtils.

public static VkApplicationInfo
create(long address)

Returns a new VkApplicationInfo instance for the specified memory address.

public static VkApplicationInfo.Buffer
create(int
the buffer capacity
capacity
)

Returns a new VkApplicationInfo.Buffer instance allocated with BufferUtils.

public static VkApplicationInfo.Buffer
create(long
the memory address
address
,
int
the buffer capacity
capacity
)

Create a VkApplicationInfo.Buffer instance at the specified memory.

public static VkApplicationInfo
createSafe(long address)

Like create, but returns null if address is NULL.

public static VkApplicationInfo.Buffer
createSafe(long address, int capacity)

Like create, but returns null if address is NULL.

public int
engineVersion()

an unsigned integer variable containing the developer-supplied version number of the engine used to create the application.

public VkApplicationInfo
engineVersion(int value)

Sets the specified value to the engineVersion field.

public static VkApplicationInfo
malloc()

Returns a new VkApplicationInfo instance allocated with memAlloc.

public static VkApplicationInfo.Buffer
malloc(int
the buffer capacity
capacity
)

Returns a new VkApplicationInfo.Buffer instance allocated with memAlloc.

public static VkApplicationInfo
malloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new VkApplicationInfo instance allocated on the specified MemoryStack.

public static VkApplicationInfo.Buffer
malloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new VkApplicationInfo.Buffer instance allocated on the specified MemoryStack.

public static VkApplicationInfo
mallocStack()

Deprecated
Deprecated for removal in 3.4.0.
public static VkApplicationInfo
mallocStack(MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
public static VkApplicationInfo.Buffer
mallocStack(int capacity)

Deprecated
Deprecated for removal in 3.4.0.
public static VkApplicationInfo.Buffer
mallocStack(int capacity, MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
public static int
napiVersion(long struct)

Unsafe version of apiVersion.

public static void
napiVersion(long struct, int value)

Unsafe version of apiVersion.

public static int
napplicationVersion(long struct)

Unsafe version of applicationVersion.

public static void
napplicationVersion(long struct, int value)

Unsafe version of applicationVersion.

public static int
nengineVersion(long struct)

Unsafe version of engineVersion.

public static void
nengineVersion(long struct, int value)

Unsafe version of engineVersion.

public static ByteBuffer
npApplicationName(long struct)

Unsafe version of pApplicationName.

public static void
npApplicationName(long struct, ByteBuffer value)

Unsafe version of pApplicationName.

public static String
npApplicationNameString(long struct)

Unsafe version of pApplicationNameString.

public static ByteBuffer
npEngineName(long struct)

Unsafe version of pEngineName.

public static void
npEngineName(long struct, ByteBuffer value)

Unsafe version of pEngineName.

public static String
npEngineNameString(long struct)

Unsafe version of pEngineNameString.

public static long
npNext(long struct)

Unsafe version of pNext.

public static void
npNext(long struct, long value)

Unsafe version of pNext.

public static int
nsType(long struct)

Unsafe version of sType.

public static void
nsType(long struct, int value)

Unsafe version of sType.

public ByteBuffer
pApplicationName()

NULL or is a pointer to a null-terminated UTF-8 string containing the name of the application.

public VkApplicationInfo
pApplicationName(ByteBuffer value)

Sets the address of the specified encoded string to the pApplicationName field.

public String
pApplicationNameString()

NULL or is a pointer to a null-terminated UTF-8 string containing the name of the application.

public ByteBuffer
pEngineName()

NULL or is a pointer to a null-terminated UTF-8 string containing the name of the engine (if any) used to create the application.

public VkApplicationInfo
pEngineName(ByteBuffer value)

Sets the address of the specified encoded string to the pEngineName field.

public String
pEngineNameString()

NULL or is a pointer to a null-terminated UTF-8 string containing the name of the engine (if any) used to create the application.

public long
pNext()

NULL or a pointer to a structure extending this structure.

public VkApplicationInfo
pNext(long value)

Sets the specified value to the pNext field.

public VkApplicationInfo
set(int sType, long pNext, ByteBuffer pApplicationName, int applicationVersion, ByteBuffer pEngineName, int engineVersion, int apiVersion)

Initializes this struct with the specified values.

public VkApplicationInfo

Returns:

this struct
set
(VkApplicationInfo
the source struct
src
)

Copies the specified struct data to this struct.

public int
sizeof()

Implements abstract org.lwjgl.system.Struct.sizeof.

Returns sizeof(struct).
public int
sType()

a VkStructureType value identifying this structure.

public VkApplicationInfo
sType(int value)

Sets the specified value to the sType field.

public VkApplicationInfo
sType$Default()

Sets the STRUCTURE_TYPE_APPLICATION_INFO value to the sType field.

Inherited from org.lwjgl.system.Struct:
__array__array__array__checkContainer__checkMalloc__create__getContainer__getContainer__member__member__member__padding__padding__struct__struct__union__unionclearfreeisNullvalidate