pub struct DeviceMetadata { /* private fields */ }Expand description
Metadata for after device creation.
Implementations§
Source§impl DeviceMetadata
impl DeviceMetadata
Sourcepub fn device_handle(&self) -> Device
pub fn device_handle(&self) -> Device
The device this metadata belongs to.
Sourcepub fn physical_device(&self) -> PhysicalDevice
pub fn physical_device(&self) -> PhysicalDevice
The physical device this device belongs to.
Sourcepub fn surface(&self) -> Option<SurfaceKHR>
pub fn surface(&self) -> Option<SurfaceKHR>
The surface this device was created for.
Sourcepub fn properties(&self) -> &PhysicalDeviceProperties
pub fn properties(&self) -> &PhysicalDeviceProperties
Properties of the physical device.
Sourcepub fn device_name(&self) -> Cow<'_, str>
pub fn device_name(&self) -> Cow<'_, str>
Name of the physical device.
Sourcepub fn device_type(&self) -> PhysicalDeviceType
pub fn device_type(&self) -> PhysicalDeviceType
Type of the physical device.
Sourcepub fn device_queue(
&self,
instance: &InstanceLoader,
device: &DeviceLoader,
criteria: QueueFamilyCriteria,
queue_index: u32,
) -> Result<Option<(Queue, u32)>, Result>
pub fn device_queue( &self, instance: &InstanceLoader, device: &DeviceLoader, criteria: QueueFamilyCriteria, queue_index: u32, ) -> Result<Option<(Queue, u32)>, Result>
Returns a queue and the index of the queue family it belongs to.
The best suited queue family meeting the criteria will be chosen.
queue_index is the index within the queue family.
Sourcepub fn queue_setups(&self) -> &[QueueSetup]
pub fn queue_setups(&self) -> &[QueueSetup]
The queue setups which are in use.
Sourcepub fn memory_properties(&self) -> &PhysicalDeviceMemoryProperties
pub fn memory_properties(&self) -> &PhysicalDeviceMemoryProperties
The memory properties of the physical device.
Sourcepub fn queue_family_properties(&self) -> &[QueueFamilyProperties]
pub fn queue_family_properties(&self) -> &[QueueFamilyProperties]
The queue family properties of the physical device.
Sourcepub fn enabled_extensions(&self) -> &[CString]
pub fn enabled_extensions(&self) -> &[CString]
List of all enabled extensions in the instance.
Sourcepub unsafe fn is_extension_enabled(&self, extension: *const c_char) -> bool
pub unsafe fn is_extension_enabled(&self, extension: *const c_char) -> bool
Returns true if extension is enabled.
Trait Implementations§
Source§impl Clone for DeviceMetadata
impl Clone for DeviceMetadata
Source§fn clone(&self) -> DeviceMetadata
fn clone(&self) -> DeviceMetadata
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for DeviceMetadata
impl RefUnwindSafe for DeviceMetadata
impl Send for DeviceMetadata
impl Sync for DeviceMetadata
impl Unpin for DeviceMetadata
impl UnwindSafe for DeviceMetadata
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more