| Modifier and Type | Class and Description |
|---|---|
| public static class | GLFWVulkan.
Contains the function pointers loaded from |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public static int | Returns: VK10#VK_SUCCESS if successful, or a Vulkan error code if an error occurredthe Vulkan instance to create the surface in instance, long the window to create the surface for window, VkAllocationCallbacks the allocator to use, or allocator, LongBuffer NULL to use the default allocator.where to store the handle of the surface. This is set to surface)VK10#VK_NULL_HANDLE if an error occurred.Creates a Vulkan surface for the specified window. |
| public static int | glfwCreateWindowSurface(VkInstance instance, long window, VkAllocationCallbacks allocator, long[] surface)
Array version of: |
| public static long | Returns: the address of the function, orNULL if an error occurredthe Vulkan instance to query, or instance, ByteBuffer NULL to retrieve functions related to instance creationthe ASCII encoded name of the function procname)Returns the address of the specified Vulkan core or extension function for the specified instance. |
| public static long | Returns: the address of the function, orNULL if an error occurredthe Vulkan instance to query, or instance, CharSequence NULL to retrieve functions related to instance creationthe ASCII encoded name of the function procname)Returns the address of the specified Vulkan core or extension function for the specified instance. |
| public static boolean | glfwGetPhysicalDevicePresentationSupport(VkInstance
the instance that the physical device belongs to instance, VkPhysicalDevice the physical device that the queue family belongs to device, int the index of the queue family to query queuefamily)Returns whether the specified queue family of the specified physical device supports presentation to the platform GLFW was built for. |
| public static PointerBuffer | Returns: an array of ASCII encoded extension names, orNULL if an error occurredReturns an array of names of Vulkan instance extensions required by GLFW for creating Vulkan surfaces for GLFW windows. |
| public static void | glfwInitVulkanLoader(long
the address of the function to use, or loader)NULLSets the desired Vulkan |
| public static boolean | |
| public static int | nglfwCreateWindowSurface(long instance, long window, long allocator, long surface)
Unsafe version of: |
| public static long | |
| public static long | nglfwGetRequiredInstanceExtensions(long
where to store the number of extensions in the returned array. This is set to zero if an error occurred. count)Unsafe version of: |
| public static void | setPath(FunctionProvider
a sharedLibrary)FunctionProvider instance that will be cast to SharedLibraryCalls |
| public static void |
| GLFWVulkan | back to summary |
|---|---|
| protected GLFWVulkan() | |
| glfwCreateWindowSurface | back to summary |
|---|---|
| public static int glfwCreateWindowSurface(VkInstance instance, long window, VkAllocationCallbacks allocator, LongBuffer surface) Creates a Vulkan surface for the specified window. If the Vulkan loader was not found at initialization, this function returns If the required window surface creation instance extensions are not available or if the specified instance was not created with these extensions
enabled, this function returns The window surface cannot be shared with another API so the window must have been created with the client api hint set to The window surface must be destroyed before the specified Vulkan instance. It is the responsibility of the caller to destroy the window surface. GLFW
does not destroy it for you. Call Possible errors include If an error occurs before the creation call is made, GLFW returns the Vulkan error code most appropriate for the error. Appropriate use of
Notes:
| |
| glfwCreateWindowSurface | back to summary |
|---|---|
| public static int glfwCreateWindowSurface(VkInstance instance, long window, VkAllocationCallbacks allocator, long[] surface) Array version of:
| |
| glfwGetInstanceProcAddress | back to summary |
|---|---|
| public static long glfwGetInstanceProcAddress(VkInstance instance, ByteBuffer procname) Returns the address of the specified Vulkan core or extension function for the specified instance. If instance is set to
If Vulkan is not available on the machine, this function returns This function is equivalent to calling Possible errors include The returned function pointer is valid until the library is terminated. This function may be called from any thread.
| |
| glfwGetInstanceProcAddress | back to summary |
|---|---|
| public static long glfwGetInstanceProcAddress(VkInstance instance, CharSequence procname) Returns the address of the specified Vulkan core or extension function for the specified instance. If instance is set to
If Vulkan is not available on the machine, this function returns This function is equivalent to calling Possible errors include The returned function pointer is valid until the library is terminated. This function may be called from any thread.
| |
| glfwGetPhysicalDevicePresentationSupport | back to summary |
|---|---|
| public static boolean glfwGetPhysicalDevicePresentationSupport(VkInstance instance, VkPhysicalDevice device, int queuefamily) Returns whether the specified queue family of the specified physical device supports presentation to the platform GLFW was built for. If Vulkan or the required window surface creation instance extensions are not available on the machine, or if the specified instance was not created
with the required extensions, this function returns Possible errors include macOS: This function currently always returns This function may be called from any thread. For synchronization details of Vulkan objects, see the Vulkan specification.
| |
| glfwGetRequiredInstanceExtensions | back to summary |
|---|---|
| public static PointerBuffer glfwGetRequiredInstanceExtensions() Returns an array of names of Vulkan instance extensions required by GLFW for creating Vulkan surfaces for GLFW windows. If successful, the list will
always contain If Vulkan is not available on the machine, this function returns If Vulkan is available but no set of extensions allowing window surface creation was found, this function returns Additional extensions may be required by future versions of GLFW. You should check if any extensions you wish to enable are already in the returned
array, as it is an error to specify an extension more than once in the The returned array is allocated and freed by GLFW. You should not free it yourself. It is guaranteed to be valid only until the library is terminated. This function may be called from any thread. Possible errors include
| |
| glfwInitVulkanLoader | back to summary |
|---|---|
| public static void glfwInitVulkanLoader(long loader) Sets the desired Vulkan This function sets the This feature is mostly useful on macOS, if your copy of the Vulkan loader is in a location where GLFW cannot find it through dynamic loading, or if you are still using the static library version of the loader. If set to The standard name of the loader is The function address you set is never reset by GLFW, but it only takes effect during initialization. Once GLFW has been initialized, any updates will be ignored until the library is terminated and initialized again. This function may be called before This function must only be called from the main thread.
| |
| glfwVulkanSupported | back to summary |
|---|---|
| public static boolean glfwVulkanSupported() Returns whether the Vulkan loader has been found. This check is performed by The availability of a Vulkan loader and even an ICD does not by itself guarantee that surface creation or even instance creation is possible. Call
Possible errors include This function may be called from any thread.
| |
| nglfwCreateWindowSurface | back to summary |
|---|---|
| public static int nglfwCreateWindowSurface(long instance, long window, long allocator, long surface) Unsafe version of: | |
| nglfwGetInstanceProcAddress | back to summary |
|---|---|
| public static long nglfwGetInstanceProcAddress(long instance, long procname) Unsafe version of: | |
| nglfwGetRequiredInstanceExtensions | back to summary |
|---|---|
| public static long nglfwGetRequiredInstanceExtensions(long count) Unsafe version of:
| |
| setPath | back to summary |
|---|---|
| public static void setPath(FunctionProvider sharedLibrary) Calls Example usage:
| |
| setPath | back to summary |
|---|---|
| public static void setPath(String path) Overrides the Vulkan shared library that GLFW loads internally. This is useful when there's a mismatch between the shared libraries loaded by LWJGL and GLFW. This method must be called before GLFW initializes Vulkan. The override is available only in the default GLFW build bundled with LWJGL. Using the
override with a custom GLFW build will produce a warning in
| |
GLFW.getLibrary().
| Modifier and Type | Field and Description |
|---|---|
| public static final long | CreateWindowSurface
Function address. |
| public static final long | GetInstanceProcAddress
Function address. |
| public static final long | GetPhysicalDevicePresentationSupport
Function address. |
| public static final long | GetRequiredInstanceExtensions
Function address. |
| public static final long | InitVulkanLoader
Function address. |
| public static final long | VulkanSupported
Function address. |
| Access | Constructor and Description |
|---|---|
| private |
| CreateWindowSurface | back to summary |
|---|---|
| public static final long CreateWindowSurface Function address. | |
| GetInstanceProcAddress | back to summary |
|---|---|
| public static final long GetInstanceProcAddress Function address. | |
| GetPhysicalDevicePresentationSupport | back to summary |
|---|---|
| public static final long GetPhysicalDevicePresentationSupport Function address. | |
| GetRequiredInstanceExtensions | back to summary |
|---|---|
| public static final long GetRequiredInstanceExtensions Function address. | |
| InitVulkanLoader | back to summary |
|---|---|
| public static final long InitVulkanLoader Function address. | |
| VulkanSupported | back to summary |
|---|---|
| public static final long VulkanSupported Function address. | |
| Functions | back to summary |
|---|---|
| private Functions() | |