Skip to main content

Crate ferroui_vulkan

Crate ferroui_vulkan 

Source
Expand description

The Vulkan platform contracts and the platform graphics over them.

What a platform exposes so that a render backend can draw with Vulkan: the instance and the device (IVulkanInstance, IVulkanDevice), the graphics context of a device (IVulkanPlatformGraphicsContext), the surfaces a context presents to (IVulkanKhrSurfacePlatformSurface, IVulkanKhrSurfacePlatformSurfaceFactory, IVulkanRenderTargetPlatformSurface), the render target of a surface and the session of a frame (IVulkanRenderTarget, IVulkanRenderSession), and the import of images and semaphores that were created outside of a device (IVulkanContextExternalObjectsFeature).

And the implementation every windowing platform shares (VulkanPlatformGraphics): it creates the instance (with the debug messenger when asked), selects a physical device, creates the device with its queue, and gives each thread that renders a context whose render targets present through a swap chain. A platform adds three things (VulkanPlatformSpecificOptions): the way to the entry points of the Vulkan loader, the instance extensions of its window system, and the factory that turns its windows into surfaces.

These types belong to no render backend. The types, constants and function tables of Vulkan are those of the ash crate, which is exported again for the crates that implement or read the contracts; the loader of the system is opened at run time (ash::Entry::load), and nothing is linked.

Re-exports§

pub use ash;

Modules§

unmanaged_interop
The entry points, structures and enumerations of Vulkan.

Structs§

Version
A version number of three parts.
VulkanDeviceCreationOptions
VulkanException
A failure reported by Vulkan or by the code driving it.
VulkanHelpers
Values of the Vulkan headers that are computed and not enumerated.
VulkanImageInfo
A Vulkan image as a render backend needs to know it: the handles are those of the device of the context that hands the value out, the other members are the numeric values of the Vulkan enumerations.
VulkanInstanceCreationOptions
VulkanOptions
How an application wants Vulkan to be set up.
VulkanPlatformGraphics
The platform graphics of Vulkan: creates the graphics contexts of the threads that render, each over a device of its own or all over the device of the application.
VulkanPlatformSpecificOptions
What a windowing platform adds to the options of the application.

Traits§

IVulkanContextExternalObjectsFeature
Lets a Vulkan context import images and semaphores that were created outside of it (by another device or another process).
IVulkanDevice
A Vulkan device with the queue the framework renders with.
IVulkanDeviceFactory
Where the devices of the contexts come from.
IVulkanExternalImage
An image of a Vulkan device that was imported from an external image.
IVulkanExternalSemaphore
A semaphore of a Vulkan device that was imported from a handle.
IVulkanInstance
A Vulkan instance and the way to its entry points.
IVulkanKhrSurfacePlatformSurface
A surface that is presented to through a VkSurfaceKHR and a swap chain.
IVulkanKhrSurfacePlatformSurfaceFactory
Lets a context present to surfaces that are not Vulkan surfaces themselves (the window of a platform).
IVulkanPlatformGraphicsContext
A platform graphics context that renders with Vulkan.
IVulkanRenderSession
One frame being rendered with Vulkan. Disposing the session presents the frame.
IVulkanRenderTarget
The Vulkan render target of a surface.
IVulkanRenderTargetPlatformSurface
A platform render surface that provides its own IVulkanRenderTarget, e.g. an offscreen image-based target that doesn’t involve a swapchain.
VulkanExceptionExtensions
Turns every result but VK_SUCCESS into a failure.
VulkanResultExtensions
Names the function whose result a failure is.

Functions§

try_get_vulkan_khr_surface
The render surface viewed as a surface with a VkSurfaceKHR, when it is one.
try_get_vulkan_render_target_surface
The render surface viewed as a surface with its own Vulkan render target, when it is one.

Type Aliases§

VkGetInstanceProcAddressDelegate
The address of an instance-level entry point of Vulkan by its name (vkGetInstanceProcAddr): the instance, zero for the entry points that need none, and the name; zero when there is no such entry point.
VulkanDeviceCheckSurfaceFactory
Creates a VkSurfaceKHR on an instance, for asking the physical devices whether they can present. Zero stands for no surface: the devices are not asked then. A failure is the failure of the creation of the device.