Calls release(), for await using.
Hosts without Symbol.asyncDispose, such as ArkTS, leave it undefined.
Calls release(), for using.
Hosts without Symbol.dispose, such as ArkTS, leave it undefined.
ReadonlyidThe native handle value. It stays readable after release.
Whether a release, dispose, or discard has ended the handle.
Gets the context to attach render sessions to the device with.
Pass it as the context of MapHandle.attachVulkanSurface() or
MapHandle.attachVulkanBorrowedTexture(). The sessions on the device share
its graphics queue. To submit to the queue yourself, set
RenderSessionAttachOptions.queueLock on each session.
See mln_vulkan_device_get_context in the
C API reference.
Releases a Vulkan device.
Render sessions that attached with the device's context keep using it until they detach or their release finishes.
See mln_vulkan_device_release in the
C API reference.
Names the owner's type, its handle ID, and whether it is closed.
StaticcreateCreates a Vulkan instance, device, and graphics queue for render sessions.
Attach sessions with the context from VulkanDeviceHandle.getContext(), in
place of a device of your own. Without device_uuid or device_luid, it
prefers a discrete GPU. The device enables the external memory and
semaphore extensions that the GPU offers.
See mln_vulkan_device_create in the
C API reference.
Errors:
Status.unsupported when supportedRenderBackendMask() lacks
RenderBackendFlag.vulkan, or when presentation is true and the Vulkan
loader or the GPU can't present.Status.notFound when no GPU matches device_uuid and device_luid.Status.nativeError when there is no Vulkan loader, no GPU has a
graphics queue, or Vulkan can't create the instance or the device.Optionaloptions: VulkanDeviceOptions
A Vulkan instance, device, and queue that the library creates and owns.
See
mln_vulkan_devicein the C API reference.