Struct PhysicalDeviceObject

Source
pub struct PhysicalDeviceObject<Owner: Instance>(/* private fields */);
Expand description

Opaque handle to a physical device object

§Platform Dependent Methods: Presentation Support checking functions

  • xlib_presentation_support(&self, queue_family: u32, display: *mut x11::xlib::Display, visual: x11::xlib::VisualID) -> bool: VK_KHR_xlib_surface
  • xcb_presentation_support(&self, queue_family: u32, connection: *mut xcb::ffi::xcb_connection_t, visual: xcb::ffi::xcb_visualid_t) -> bool: VK_KHR_xcb_surface
  • wayland_presentation_support(&self, queue_family: u32, display: *mut wayland_client::sys::wl_display) -> bool: VK_KHR_wayland_surface
  • win32_presentation_support(&self, queue_family: u32) -> bool: VK_KHR_win32_surface
  • Methods for Android and Mir surfaces are not implemented

Implementations§

Source§

impl<Owner: Instance> PhysicalDeviceObject<Owner>

Source

pub const unsafe fn manage(handle: VkPhysicalDevice, owner: Owner) -> Self

Source

pub const fn unmanage(self) -> (VkPhysicalDevice, Owner)

Source§

impl<Owner: Instance + Clone> PhysicalDeviceObject<&Owner>

Source

pub fn clone_parent(&self) -> PhysicalDeviceObject<Owner>

Split the lifetime from owner by cloning it.

Trait Implementations§

Source§

impl<Owner: Clone + Instance> Clone for PhysicalDeviceObject<Owner>

Source§

fn clone(&self) -> PhysicalDeviceObject<Owner>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<Owner: Instance> InstanceChild for PhysicalDeviceObject<Owner>

Source§

impl<Owner: Instance> InstanceChildTransferrable for PhysicalDeviceObject<Owner>

Source§

impl<Owner: Instance> PhysicalDevice for PhysicalDeviceObject<Owner>

Source§

fn layer_property_count(&self) -> Result<u32>

Returns a count of properties of available physical device layers Read more
Source§

fn enumerate_layer_properties( &self, sink: &mut [MaybeUninit<VkLayerProperties>], ) -> Result<u32>

Returns properties of available physical device layers Read more
Source§

fn enumerate_layer_properties_alloc(&self) -> Result<Vec<VkLayerProperties>>

Returns properties of available physical device layers Read more
Source§

fn extension_property_count_cstr( &self, layer_name: Option<&CStr>, ) -> Result<u32>

Returns a count of properties of available physical device extensions Read more
Source§

fn enumerate_extension_properties_cstr( &self, layer_name: Option<&CStr>, sink: &mut [MaybeUninit<VkExtensionProperties>], ) -> Result<u32>

Returns properties of available physical device extensions Read more
Source§

fn enumerate_extension_properties_cstr_alloc( &self, layer_name: Option<&CStr>, ) -> Result<Vec<VkExtensionProperties>>

Returns properties of available physical device extensions Read more
Source§

fn enumerate_extension_properties( &self, layer_name: Option<&str>, ) -> Result<Vec<VkExtensionProperties>>

Returns properties of available physical device extensions Read more
Source§

fn features(&self) -> VkPhysicalDeviceFeatures

Reports capabilities of a physical device.
Source§

unsafe fn features2_khr( &self, sink: &mut MaybeUninit<VkPhysicalDeviceFeatures2KHR>, )

Reports capabilities of a physical device Read more
Source§

fn properties(&self) -> VkPhysicalDeviceProperties

Returns properties of a physical device
Source§

unsafe fn properties2_khr( &self, sink: &mut MaybeUninit<VkPhysicalDeviceProperties2KHR>, )

Returns properties of a physical device Read more
Source§

fn format_properties(&self, format: VkFormat) -> VkFormatProperties

Lists physical device’s format capabilities
Source§

unsafe fn format_properties2_khr( &self, format: VkFormat, out: &mut MaybeUninit<VkFormatProperties2KHR>, )

Lists physical device’s format capabilities Read more
Source§

fn image_format_properties( &self, format: VkFormat, itype: VkImageType, tiling: VkImageTiling, usage: ImageUsageFlags, flags: ImageFlags, ) -> Result<VkImageFormatProperties>

Lists physical device’s image format capabilities Read more
Source§

fn queue_family_property_count(&self) -> u32

Reports a count of properties of the queues of the specified physical device
Source§

fn queue_family_properties( &self, sink: &mut [MaybeUninit<VkQueueFamilyProperties>], ) -> u32

Reports properties of the queues of the specified physical device
Source§

fn queue_family_properties_alloc(&self) -> QueueFamilies

Reports properties of the queues of the specified physical device
Source§

fn memory_properties(&self) -> MemoryProperties

Reports memory information for the specified physical device
Source§

fn sparse_image_format_property_count( &self, format: VkFormat, image_type: VkImageType, samples: VkSampleCountFlags, usage: ImageUsageFlags, tiling: VkImageTiling, ) -> u32

Retrieve a count of properties of an image format spplied to sparse images
Source§

fn sparse_image_format_properties( &self, format: VkFormat, image_type: VkImageType, samples: VkSampleCountFlags, usage: ImageUsageFlags, tiling: VkImageTiling, sink: &mut [MaybeUninit<VkSparseImageFormatProperties>], ) -> u32

Retrieve properties of an image format applied to sparse images
Source§

fn sparse_image_format_properties_alloc( &self, format: VkFormat, itype: VkImageType, samples: VkSampleCountFlags, usage: ImageUsageFlags, tiling: VkImageTiling, ) -> Vec<VkSparseImageFormatProperties>

Retrieve properties of an image format applied to sparse images
Source§

fn surface_support( &self, queue_family: u32, surface: &(impl Surface + ?Sized), ) -> Result<bool>

Query if presentation is supported Read more
Source§

fn surface_capabilities( &self, surface: &(impl Surface + ?Sized), ) -> Result<VkSurfaceCapabilitiesKHR>

Query surface capabilities Read more
Source§

fn surface_format_count( &self, surface: &(impl VkHandle<Handle = VkSurfaceKHR> + ?Sized), ) -> Result<u32>

Query a count of color formats supported by surface Read more
Source§

fn surface_formats( &self, surface: &(impl VkHandle<Handle = VkSurfaceKHR> + ?Sized), sink: &mut [MaybeUninit<VkSurfaceFormatKHR>], ) -> Result<u32>

Query a count of color formats supported by surface Read more
Source§

fn surface_formats_alloc( &self, surface: &(impl Surface + ?Sized), ) -> Result<Vec<VkSurfaceFormatKHR>>

Query color formats supported by surface Read more
Source§

fn surface_present_mode_count( &self, surface: &(impl VkHandle<Handle = VkSurfaceKHR> + ?Sized), ) -> Result<u32>

Query a count of supported presentation modes Read more
Source§

fn surface_present_modes( &self, surface: &(impl VkHandle<Handle = VkSurfaceKHR> + ?Sized), sink: &mut [MaybeUninit<PresentMode>], ) -> Result<u32>

Query supported presentation modes Read more
Source§

fn surface_present_modes_alloc( &self, surface: &(impl Surface + ?Sized), ) -> Result<Vec<PresentMode>>

Query supported presentation modes Read more
Source§

impl<Owner: Instance> VkHandle for PhysicalDeviceObject<Owner>

Source§

type Handle = VkPhysicalDevice

Source§

fn native_ptr(&self) -> Self::Handle

Retrieve an underlying handle
Source§

fn as_transparent_ref(&self) -> VkHandleRef<'_, Self::Handle>

Source§

impl<Owner: Instance> VkHandleMut for PhysicalDeviceObject<Owner>

Source§

fn native_ptr_mut(&mut self) -> Self::Handle

Retrieve an underlying mutable handle
Source§

fn as_transparent_ref_mut(&mut self) -> VkHandleRefMut<'_, Self::Handle>

Source§

impl<Owner: Instance> VkObject for PhysicalDeviceObject<Owner>

Source§

impl<Owner: Instance + Send> Send for PhysicalDeviceObject<Owner>

Source§

impl<Owner: Instance + Sync> Sync for PhysicalDeviceObject<Owner>

Auto Trait Implementations§

§

impl<Owner> Freeze for PhysicalDeviceObject<Owner>
where Owner: Freeze,

§

impl<Owner> RefUnwindSafe for PhysicalDeviceObject<Owner>
where Owner: RefUnwindSafe,

§

impl<Owner> Unpin for PhysicalDeviceObject<Owner>
where Owner: Unpin,

§

impl<Owner> UnwindSafe for PhysicalDeviceObject<Owner>
where Owner: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> VkHandleExt for T
where T: VkHandle,

Source§

fn eq_handle(&self, other: &Self) -> bool
where Self::Handle: VkRawHandle,

Checks the equality between vulkan objects by their handle value.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more