khr_swapchain1_1

package
v2.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 26, 2022 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AcquireNextImageInfo

type AcquireNextImageInfo struct {
	// Swapchain is the khr_swapchain.Swapchain from which an Image is acquired
	Swapchain khr_swapchain.Swapchain
	// Timeout is how long to wait, in nanoseconds, if no Image is available, before returning core1_0.VKTimeout.
	// May be common.NoTimeout to wait indefinitely. The timeout is adjusted to the closest value allowed by the
	// implementation timeout accuracy, which may be substantially longer than the requested timeout.
	Timeout time.Duration
	// Semaphore is, optionally, a Semaphore to signal when acquisition is complete
	Semaphore core1_0.Semaphore
	// Fence is, optionally, a Fence to signal when acquisition is complete
	Fence core1_0.Fence
	// DeviceMask is a mask of PhysicalDevice objects for which the khr_swapchain.Swapchain Image will be
	// ready to use when the Semaphore or Fence is signaled
	DeviceMask uint32

	common.NextOptions
}

AcquireNextImageInfo specifies parameters of the acquire operation

https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkAcquireNextImageInfoKHR.html

func (AcquireNextImageInfo) PopulateCPointer

func (o AcquireNextImageInfo) PopulateCPointer(allocator *cgoparam.Allocator, preallocatedPointer unsafe.Pointer, next unsafe.Pointer) (unsafe.Pointer, error)

type DeviceGroupPresentCapabilities

type DeviceGroupPresentCapabilities struct {
	// PresentMask is an array of masks, where the mask at element i is non-zero if PhysicalDevice i
	// has a presentation engine, and where bit j is set in element i if PhysicalDevice i can present
	// swapchain Image objects from PhysicalDevice j
	PresentMask [core1_1.MaxGroupSize]uint32
	// Modes indicates which Device group presentation modes are supported
	Modes DeviceGroupPresentModeFlags

	common.NextOutData
}

DeviceGroupPresentCapabilities returns present capabilities from other PhysicalDevice objects

https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkDeviceGroupPresentCapabilitiesKHR.html

func (*DeviceGroupPresentCapabilities) PopulateHeader

func (o *DeviceGroupPresentCapabilities) PopulateHeader(allocator *cgoparam.Allocator, preallocatedPointer unsafe.Pointer, next unsafe.Pointer) (unsafe.Pointer, error)

func (*DeviceGroupPresentCapabilities) PopulateOutData

func (o *DeviceGroupPresentCapabilities) PopulateOutData(cDataPointer unsafe.Pointer, helpers ...any) (next unsafe.Pointer, err error)

type DeviceGroupPresentModeFlags

type DeviceGroupPresentModeFlags int32

DeviceGroupPresentModeFlags specifies supported Device group present modes

https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkDeviceGroupPresentModeFlagBitsKHR.html

const (
	// DeviceGroupPresentModeLocal specifies that any PhysicalDevice with a presentation engine can
	// present its own Swapchain Image objects
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkDeviceGroupPresentModeFlagBitsKHR.html
	DeviceGroupPresentModeLocal DeviceGroupPresentModeFlags = C.VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_BIT_KHR
	// DeviceGroupPresentModeRemote specifies that any PhysicalDevice with a presentation engine can
	// present Swapchain Image objects from any PhysicalDevice in its PresentMask
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkDeviceGroupPresentModeFlagBitsKHR.html
	DeviceGroupPresentModeRemote DeviceGroupPresentModeFlags = C.VK_DEVICE_GROUP_PRESENT_MODE_REMOTE_BIT_KHR
	// DeviceGroupPresentModeSum specifies that any PhysicalDevice with a presentation engine can present
	// the sum of Swapchain Image objects from any PhysicalDevice in its PresentMask
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkDeviceGroupPresentModeFlagBitsKHR.html
	DeviceGroupPresentModeSum DeviceGroupPresentModeFlags = C.VK_DEVICE_GROUP_PRESENT_MODE_SUM_BIT_KHR
	// DeviceGroupPresentModeLocalMultiDevice specifies that multiple PhysicalDevice objects with a presentation
	// engine can each present their own Swapchain Image objects
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkDeviceGroupPresentModeFlagBitsKHR.html
	DeviceGroupPresentModeLocalMultiDevice DeviceGroupPresentModeFlags = C.VK_DEVICE_GROUP_PRESENT_MODE_LOCAL_MULTI_DEVICE_BIT_KHR
)

func (DeviceGroupPresentModeFlags) Register

func (f DeviceGroupPresentModeFlags) Register(str string)

func (DeviceGroupPresentModeFlags) String

type Extension

type Extension interface {
	// AcquireNextImage2 retrieves the index of the next available presentable Image
	//
	// device - The Device which owns the requested khr_swapchain.Swapchain
	//
	// o - Contains parameters of the acquire operation
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkAcquireNextImage2KHR.html
	AcquireNextImage2(device core1_0.Device, o AcquireNextImageInfo) (int, common.VkResult, error)
	// DeviceGroupPresentCapabilities queries Device group present capabilities for a surface
	//
	// device - The Device being queried
	//
	// outData - A pre-allocated object in which the capabilities will be populated. It should include any desired
	// chained OutData objects
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkGetDeviceGroupPresentCapabilitiesKHR.html
	DeviceGroupPresentCapabilities(device core1_0.Device, outData *DeviceGroupPresentCapabilities) (common.VkResult, error)
	// DeviceGroupSurfacePresentModes queries present capabilities for a khr_surface.Surface
	//
	// device - The Device being queried
	//
	// surface - The Surface whose present capabilities are being requested
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkGetDeviceGroupSurfacePresentModesKHR.html
	DeviceGroupSurfacePresentModes(device core1_0.Device, surface khr_surface.Surface) (DeviceGroupPresentModeFlags, common.VkResult, error)
	// PhysicalDevicePresentRectangles queries present rectangles for a khr_surface.Surface on a PhysicalDevice
	//
	// physicalDevice - The PhysicalDevice being queried
	//
	// surface - The Surface whose present rectangles are being requested
	//
	// https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkGetPhysicalDevicePresentRectanglesKHR.html
	PhysicalDevicePresentRectangles(physicalDevice core1_0.PhysicalDevice, surface khr_surface.Surface) ([]core1_0.Rect2D, common.VkResult, error)
}

Extension contains all the core1.1-only commands for the khr_swapchain extension

https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VK_KHR_swapchain.html

type VulkanExtension

type VulkanExtension struct {
	khr_swapchain.Extension
	// contains filtered or unexported fields
}

VulkanExtension is an implementation of the Extension interface that actually communicates with Vulkan. This is the default implementation. See the interface for more documentation.

func CreateExtensionFromDriver

func CreateExtensionFromDriver(driver khr_swapchain_driver.Driver) *VulkanExtension

CreateExtensionFromDriver generates an Extension from a driver.Driver object- this is usually used in tests to build an Extension from mock drivers

func PromoteExtension

func PromoteExtension(extension khr_swapchain.Extension) *VulkanExtension

PromoteExtension accepts a khr_swapchain.Extension object from core 1.0. If provided an Extension that supports at least core 1.1, it will return a core1_1.Extension. Otherwise, it will return nil.

func (*VulkanExtension) AcquireNextImage2

func (v *VulkanExtension) AcquireNextImage2(device core1_0.Device, o AcquireNextImageInfo) (int, common.VkResult, error)

func (*VulkanExtension) DeviceGroupPresentCapabilities

func (v *VulkanExtension) DeviceGroupPresentCapabilities(device core1_0.Device, outData *DeviceGroupPresentCapabilities) (common.VkResult, error)

func (*VulkanExtension) DeviceGroupSurfacePresentModes

func (v *VulkanExtension) DeviceGroupSurfacePresentModes(device core1_0.Device, surface khr_surface.Surface) (DeviceGroupPresentModeFlags, common.VkResult, error)

func (*VulkanExtension) PhysicalDevicePresentRectangles

func (v *VulkanExtension) PhysicalDevicePresentRectangles(physicalDevice core1_0.PhysicalDevice, surface khr_surface.Surface) ([]core1_0.Rect2D, common.VkResult, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL