All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.lwjgl.vulkan.EXTFullScreenExclusive Maven / Gradle / Ivy

Go to download

A new generation graphics and compute API that provides high-efficiency, cross-platform access to modern GPUs used in a wide variety of devices from PCs and consoles to mobile phones and embedded platforms.

There is a newer version: 3.3.4
Show newest version
/*
 * Copyright LWJGL. All rights reserved.
 * License terms: https://www.lwjgl.org/license
 * MACHINE GENERATED FILE, DO NOT EDIT
 */
package org.lwjgl.vulkan;

import javax.annotation.*;

import java.nio.*;

import org.lwjgl.system.*;

import static org.lwjgl.system.Checks.*;
import static org.lwjgl.system.JNI.*;
import static org.lwjgl.system.MemoryUtil.*;

/**
 * This extension allows applications to set the policy for swapchain creation and presentation mechanisms relating to full-screen access. Implementations may be able to acquire exclusive access to a particular display for an application window that covers the whole screen. This can increase performance on some systems by bypassing composition, however it can also result in disruptive or expensive transitions in the underlying windowing system when a change occurs.
 * 
 * 

Applications can choose between explicitly disallowing or allowing this behavior, letting the implementation decide, or managing this mode of operation directly using the new {@link #vkAcquireFullScreenExclusiveModeEXT AcquireFullScreenExclusiveModeEXT} and {@link #vkReleaseFullScreenExclusiveModeEXT ReleaseFullScreenExclusiveModeEXT} commands.

* *
VK_EXT_full_screen_exclusive
* *
*
Name String
*
{@code VK_EXT_full_screen_exclusive}
*
Extension Type
*
Device extension
*
Registered Extension Number
*
256
*
Revision
*
4
*
Extension and Version Dependencies
*
    *
  • Requires Vulkan 1.0
  • *
  • Requires {@link KHRGetPhysicalDeviceProperties2 VK_KHR_get_physical_device_properties2}
  • *
  • Requires {@link KHRSurface VK_KHR_surface}
  • *
  • Requires {@link KHRGetSurfaceCapabilities2 VK_KHR_get_surface_capabilities2}
  • *
  • Requires {@link KHRSwapchain VK_KHR_swapchain}
  • *
*
Contact
*
*
* *
Other Extension Metadata
* *
*
Last Modified Date
*
2019-03-12
*
IP Status
*
No known IP claims.
*
Interactions and External Dependencies
*
    *
  • Interacts with Vulkan 1.1
  • *
  • Interacts with {@link KHRDeviceGroup VK_KHR_device_group}
  • *
  • Interacts with {@link KHRWin32Surface VK_KHR_win32_surface}
  • *
*
Contributors
*
    *
  • Hans-Kristian Arntzen, ARM
  • *
  • Slawomir Grajewski, Intel
  • *
  • Tobias Hector, AMD
  • *
  • James Jones, NVIDIA
  • *
  • Daniel Rakos, AMD
  • *
  • Jeff Juliano, NVIDIA
  • *
  • Joshua Schnarr, NVIDIA
  • *
  • Aaron Hagan, AMD
  • *
*
*/ public class EXTFullScreenExclusive { /** The extension specification version. */ public static final int VK_EXT_FULL_SCREEN_EXCLUSIVE_SPEC_VERSION = 4; /** The extension name. */ public static final String VK_EXT_FULL_SCREEN_EXCLUSIVE_EXTENSION_NAME = "VK_EXT_full_screen_exclusive"; /** * Extends {@code VkStructureType}. * *
Enum values:
* *
    *
  • {@link #VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT}
  • *
  • {@link #VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT}
  • *
*/ public static final int VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_INFO_EXT = 1000255000, VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_FULL_SCREEN_EXCLUSIVE_EXT = 1000255002; /** Extends {@code VkResult}. */ public static final int VK_ERROR_FULL_SCREEN_EXCLUSIVE_MODE_LOST_EXT = -1000255000; /** Extends {@code VkStructureType}. */ public static final int VK_STRUCTURE_TYPE_SURFACE_FULL_SCREEN_EXCLUSIVE_WIN32_INFO_EXT = 1000255001; /** * VkFullScreenExclusiveEXT - Hint values an application can specify affecting full-screen transition behavior * *
Description
* *
    *
  • {@link #VK_FULL_SCREEN_EXCLUSIVE_DEFAULT_EXT FULL_SCREEN_EXCLUSIVE_DEFAULT_EXT} indicates the implementation should determine the appropriate full-screen method by whatever means it deems appropriate.
  • *
  • {@link #VK_FULL_SCREEN_EXCLUSIVE_ALLOWED_EXT FULL_SCREEN_EXCLUSIVE_ALLOWED_EXT} indicates the implementation may use full-screen exclusive mechanisms when available. Such mechanisms may result in better performance and/or the availability of different presentation capabilities, but may require a more disruptive transition during swapchain initialization, first presentation and/or destruction.
  • *
  • {@link #VK_FULL_SCREEN_EXCLUSIVE_DISALLOWED_EXT FULL_SCREEN_EXCLUSIVE_DISALLOWED_EXT} indicates the implementation should avoid using full-screen mechanisms which rely on disruptive transitions.
  • *
  • {@link #VK_FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT} indicates the application will manage full-screen exclusive mode by using the {@link #vkAcquireFullScreenExclusiveModeEXT AcquireFullScreenExclusiveModeEXT} and {@link #vkReleaseFullScreenExclusiveModeEXT ReleaseFullScreenExclusiveModeEXT} commands.
  • *
* *
See Also
* *

{@link VkSurfaceFullScreenExclusiveInfoEXT}

*/ public static final int VK_FULL_SCREEN_EXCLUSIVE_DEFAULT_EXT = 0, VK_FULL_SCREEN_EXCLUSIVE_ALLOWED_EXT = 1, VK_FULL_SCREEN_EXCLUSIVE_DISALLOWED_EXT = 2, VK_FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT = 3; protected EXTFullScreenExclusive() { throw new UnsupportedOperationException(); } // --- [ vkGetPhysicalDeviceSurfacePresentModes2EXT ] --- /** * Unsafe version of: {@link #vkGetPhysicalDeviceSurfacePresentModes2EXT GetPhysicalDeviceSurfacePresentModes2EXT} * * @param pPresentModeCount a pointer to an integer related to the number of presentation modes available or queried, as described below. */ public static int nvkGetPhysicalDeviceSurfacePresentModes2EXT(VkPhysicalDevice physicalDevice, long pSurfaceInfo, long pPresentModeCount, long pPresentModes) { long __functionAddress = physicalDevice.getCapabilities().vkGetPhysicalDeviceSurfacePresentModes2EXT; if (CHECKS) { check(__functionAddress); } return callPPPPI(physicalDevice.address(), pSurfaceInfo, pPresentModeCount, pPresentModes, __functionAddress); } /** * Query supported presentation modes. * *
C Specification
* *

Alternatively, to query the supported presentation modes for a surface combined with select other fixed swapchain creation parameters, call:

* *

     * VkResult vkGetPhysicalDeviceSurfacePresentModes2EXT(
     *     VkPhysicalDevice                            physicalDevice,
     *     const VkPhysicalDeviceSurfaceInfo2KHR*      pSurfaceInfo,
     *     uint32_t*                                   pPresentModeCount,
     *     VkPresentModeKHR*                           pPresentModes);
* *
Description
* *

{@code vkGetPhysicalDeviceSurfacePresentModes2EXT} behaves similarly to {@link KHRSurface#vkGetPhysicalDeviceSurfacePresentModesKHR GetPhysicalDeviceSurfacePresentModesKHR}, with the ability to specify extended inputs via chained input structures.

* *
Valid Usage
* *
    *
  • {@code pSurfaceInfo→surface} must be supported by {@code physicalDevice}, as reported by {@link KHRSurface#vkGetPhysicalDeviceSurfaceSupportKHR GetPhysicalDeviceSurfaceSupportKHR} or an equivalent platform-specific mechanism
  • *
* *
Valid Usage (Implicit)
* *
    *
  • {@code physicalDevice} must be a valid {@code VkPhysicalDevice} handle
  • *
  • {@code pSurfaceInfo} must be a valid pointer to a valid {@link VkPhysicalDeviceSurfaceInfo2KHR} structure
  • *
  • {@code pPresentModeCount} must be a valid pointer to a {@code uint32_t} value
  • *
  • If the value referenced by {@code pPresentModeCount} is not 0, and {@code pPresentModes} is not {@code NULL}, {@code pPresentModes} must be a valid pointer to an array of {@code pPresentModeCount} {@code VkPresentModeKHR} values
  • *
* *
Return Codes
* *
*
On success, this command returns
*
    *
  • {@link VK10#VK_SUCCESS SUCCESS}
  • *
  • {@link VK10#VK_INCOMPLETE INCOMPLETE}
  • *
*
On failure, this command returns
*
    *
  • {@link VK10#VK_ERROR_OUT_OF_HOST_MEMORY ERROR_OUT_OF_HOST_MEMORY}
  • *
  • {@link VK10#VK_ERROR_OUT_OF_DEVICE_MEMORY ERROR_OUT_OF_DEVICE_MEMORY}
  • *
  • {@link KHRSurface#VK_ERROR_SURFACE_LOST_KHR ERROR_SURFACE_LOST_KHR}
  • *
*
* *
See Also
* *

{@link VkPhysicalDeviceSurfaceInfo2KHR}

* * @param physicalDevice the physical device that will be associated with the swapchain to be created, as described for {@link KHRSwapchain#vkCreateSwapchainKHR CreateSwapchainKHR}. * @param pSurfaceInfo a pointer to a {@link VkPhysicalDeviceSurfaceInfo2KHR} structure describing the surface and other fixed parameters that would be consumed by {@link KHRSwapchain#vkCreateSwapchainKHR CreateSwapchainKHR}. * @param pPresentModeCount a pointer to an integer related to the number of presentation modes available or queried, as described below. * @param pPresentModes either {@code NULL} or a pointer to an array of {@code VkPresentModeKHR} values, indicating the supported presentation modes. */ @NativeType("VkResult") public static int vkGetPhysicalDeviceSurfacePresentModes2EXT(VkPhysicalDevice physicalDevice, @NativeType("VkPhysicalDeviceSurfaceInfo2KHR const *") VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo, @NativeType("uint32_t *") IntBuffer pPresentModeCount, @Nullable @NativeType("VkPresentModeKHR *") IntBuffer pPresentModes) { if (CHECKS) { check(pPresentModeCount, 1); checkSafe(pPresentModes, pPresentModeCount.get(pPresentModeCount.position())); } return nvkGetPhysicalDeviceSurfacePresentModes2EXT(physicalDevice, pSurfaceInfo.address(), memAddress(pPresentModeCount), memAddressSafe(pPresentModes)); } // --- [ vkAcquireFullScreenExclusiveModeEXT ] --- /** * Acquire full-screen exclusive mode for a swapchain. * *
C Specification
* *

To acquire exclusive full-screen access for a swapchain, call:

* *

     * VkResult vkAcquireFullScreenExclusiveModeEXT(
     *     VkDevice                                    device,
     *     VkSwapchainKHR                              swapchain);
* *
Valid Usage
* *
    *
  • {@code swapchain} must not be in the retired state
  • *
  • {@code swapchain} must be a swapchain created with a {@link VkSurfaceFullScreenExclusiveInfoEXT} structure, with {@code fullScreenExclusive} set to {@link #VK_FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT}
  • *
  • {@code swapchain} must not currently have exclusive full-screen access
  • *
* *

A return value of {@link VK10#VK_SUCCESS SUCCESS} indicates that the {@code swapchain} successfully acquired exclusive full-screen access. The swapchain will retain this exclusivity until either the application releases exclusive full-screen access with {@link #vkReleaseFullScreenExclusiveModeEXT ReleaseFullScreenExclusiveModeEXT}, destroys the swapchain, or if any of the swapchain commands return {@link #VK_ERROR_FULL_SCREEN_EXCLUSIVE_MODE_LOST_EXT ERROR_FULL_SCREEN_EXCLUSIVE_MODE_LOST_EXT} indicating that the mode was lost because of platform-specific changes.

* *

If the swapchain was unable to acquire exclusive full-screen access to the display then {@link VK10#VK_ERROR_INITIALIZATION_FAILED ERROR_INITIALIZATION_FAILED} is returned. An application can attempt to acquire exclusive full-screen access again for the same swapchain even if this command fails, or if {@link #VK_ERROR_FULL_SCREEN_EXCLUSIVE_MODE_LOST_EXT ERROR_FULL_SCREEN_EXCLUSIVE_MODE_LOST_EXT} has been returned by a swapchain command.

* *
Valid Usage (Implicit)
* *
    *
  • {@code device} must be a valid {@code VkDevice} handle
  • *
  • {@code swapchain} must be a valid {@code VkSwapchainKHR} handle
  • *
  • Both of {@code device}, and {@code swapchain} must have been created, allocated, or retrieved from the same {@code VkInstance}
  • *
* *
Return Codes
* *
*
On success, this command returns
*
    *
  • {@link VK10#VK_SUCCESS SUCCESS}
  • *
*
On failure, this command returns
*
    *
  • {@link VK10#VK_ERROR_OUT_OF_HOST_MEMORY ERROR_OUT_OF_HOST_MEMORY}
  • *
  • {@link VK10#VK_ERROR_OUT_OF_DEVICE_MEMORY ERROR_OUT_OF_DEVICE_MEMORY}
  • *
  • {@link VK10#VK_ERROR_INITIALIZATION_FAILED ERROR_INITIALIZATION_FAILED}
  • *
  • {@link KHRSurface#VK_ERROR_SURFACE_LOST_KHR ERROR_SURFACE_LOST_KHR}
  • *
*
* * @param device the device associated with {@code swapchain}. * @param swapchain the swapchain to acquire exclusive full-screen access for. */ @NativeType("VkResult") public static int vkAcquireFullScreenExclusiveModeEXT(VkDevice device, @NativeType("VkSwapchainKHR") long swapchain) { long __functionAddress = device.getCapabilities().vkAcquireFullScreenExclusiveModeEXT; if (CHECKS) { check(__functionAddress); } return callPJI(device.address(), swapchain, __functionAddress); } // --- [ vkReleaseFullScreenExclusiveModeEXT ] --- /** * Release full-screen exclusive mode from a swapchain. * *
C Specification
* *

To release exclusive full-screen access from a swapchain, call:

* *

     * VkResult vkReleaseFullScreenExclusiveModeEXT(
     *     VkDevice                                    device,
     *     VkSwapchainKHR                              swapchain);
* *
Description
* *
Note
* *

Applications will not be able to present to {@code swapchain} after this call until exclusive full-screen access is reacquired. This is usually useful to handle when an application is minimised or otherwise intends to stop presenting for a time.

*
* *
Valid Usage
* *
    *
  • {@code swapchain} must not be in the retired state
  • *
  • {@code swapchain} must be a swapchain created with a {@link VkSurfaceFullScreenExclusiveInfoEXT} structure, with {@code fullScreenExclusive} set to {@link #VK_FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT FULL_SCREEN_EXCLUSIVE_APPLICATION_CONTROLLED_EXT}
  • *
* * @param device the device associated with {@code swapchain}. * @param swapchain the swapchain to release exclusive full-screen access from. */ @NativeType("VkResult") public static int vkReleaseFullScreenExclusiveModeEXT(VkDevice device, @NativeType("VkSwapchainKHR") long swapchain) { long __functionAddress = device.getCapabilities().vkReleaseFullScreenExclusiveModeEXT; if (CHECKS) { check(__functionAddress); } return callPJI(device.address(), swapchain, __functionAddress); } // --- [ vkGetDeviceGroupSurfacePresentModes2EXT ] --- /** Unsafe version of: {@link #vkGetDeviceGroupSurfacePresentModes2EXT GetDeviceGroupSurfacePresentModes2EXT} */ public static int nvkGetDeviceGroupSurfacePresentModes2EXT(VkDevice device, long pSurfaceInfo, long pModes) { long __functionAddress = device.getCapabilities().vkGetDeviceGroupSurfacePresentModes2EXT; if (CHECKS) { check(__functionAddress); } return callPPPI(device.address(), pSurfaceInfo, pModes, __functionAddress); } /** * Query device group present capabilities for a surface. * *
C Specification
* *

Alternatively, to query the supported device group presentation modes for a surface combined with select other fixed swapchain creation parameters, call:

* *

     * VkResult vkGetDeviceGroupSurfacePresentModes2EXT(
     *     VkDevice                                    device,
     *     const VkPhysicalDeviceSurfaceInfo2KHR*      pSurfaceInfo,
     *     VkDeviceGroupPresentModeFlagsKHR*           pModes);
* *
Description
* *

{@code vkGetDeviceGroupSurfacePresentModes2EXT} behaves similarly to {@link KHRSwapchain#vkGetDeviceGroupSurfacePresentModesKHR GetDeviceGroupSurfacePresentModesKHR}, with the ability to specify extended inputs via chained input structures.

* *
Valid Usage
* *
    *
  • {@code pSurfaceInfo→surface} must be supported by all physical devices associated with {@code device}, as reported by {@link KHRSurface#vkGetPhysicalDeviceSurfaceSupportKHR GetPhysicalDeviceSurfaceSupportKHR} or an equivalent platform-specific mechanism
  • *
* *
Valid Usage (Implicit)
* *
    *
  • {@code device} must be a valid {@code VkDevice} handle
  • *
  • {@code pSurfaceInfo} must be a valid pointer to a valid {@link VkPhysicalDeviceSurfaceInfo2KHR} structure
  • *
  • {@code pModes} must be a valid pointer to a {@code VkDeviceGroupPresentModeFlagsKHR} value
  • *
* *
Return Codes
* *
*
On success, this command returns
*
    *
  • {@link VK10#VK_SUCCESS SUCCESS}
  • *
*
On failure, this command returns
*
    *
  • {@link VK10#VK_ERROR_OUT_OF_HOST_MEMORY ERROR_OUT_OF_HOST_MEMORY}
  • *
  • {@link VK10#VK_ERROR_OUT_OF_DEVICE_MEMORY ERROR_OUT_OF_DEVICE_MEMORY}
  • *
  • {@link KHRSurface#VK_ERROR_SURFACE_LOST_KHR ERROR_SURFACE_LOST_KHR}
  • *
*
* *
See Also
* *

{@link VkPhysicalDeviceSurfaceInfo2KHR}

* * @param device the logical device. * @param pSurfaceInfo a pointer to a {@link VkPhysicalDeviceSurfaceInfo2KHR} structure describing the surface and other fixed parameters that would be consumed by {@link KHRSwapchain#vkCreateSwapchainKHR CreateSwapchainKHR}. * @param pModes a pointer to a {@code VkDeviceGroupPresentModeFlagsKHR} in which the supported device group present modes for the surface are returned. */ @NativeType("VkResult") public static int vkGetDeviceGroupSurfacePresentModes2EXT(VkDevice device, @NativeType("VkPhysicalDeviceSurfaceInfo2KHR const *") VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo, @NativeType("VkDeviceGroupPresentModeFlagsKHR *") IntBuffer pModes) { if (CHECKS) { check(pModes, 1); } return nvkGetDeviceGroupSurfacePresentModes2EXT(device, pSurfaceInfo.address(), memAddress(pModes)); } /** Array version of: {@link #vkGetPhysicalDeviceSurfacePresentModes2EXT GetPhysicalDeviceSurfacePresentModes2EXT} */ @NativeType("VkResult") public static int vkGetPhysicalDeviceSurfacePresentModes2EXT(VkPhysicalDevice physicalDevice, @NativeType("VkPhysicalDeviceSurfaceInfo2KHR const *") VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo, @NativeType("uint32_t *") int[] pPresentModeCount, @Nullable @NativeType("VkPresentModeKHR *") int[] pPresentModes) { long __functionAddress = physicalDevice.getCapabilities().vkGetPhysicalDeviceSurfacePresentModes2EXT; if (CHECKS) { check(__functionAddress); check(pPresentModeCount, 1); checkSafe(pPresentModes, pPresentModeCount[0]); } return callPPPPI(physicalDevice.address(), pSurfaceInfo.address(), pPresentModeCount, pPresentModes, __functionAddress); } /** Array version of: {@link #vkGetDeviceGroupSurfacePresentModes2EXT GetDeviceGroupSurfacePresentModes2EXT} */ @NativeType("VkResult") public static int vkGetDeviceGroupSurfacePresentModes2EXT(VkDevice device, @NativeType("VkPhysicalDeviceSurfaceInfo2KHR const *") VkPhysicalDeviceSurfaceInfo2KHR pSurfaceInfo, @NativeType("VkDeviceGroupPresentModeFlagsKHR *") int[] pModes) { long __functionAddress = device.getCapabilities().vkGetDeviceGroupSurfacePresentModes2EXT; if (CHECKS) { check(__functionAddress); check(pModes, 1); } return callPPPI(device.address(), pSurfaceInfo.address(), pModes, __functionAddress); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy