pub struct GPUInfo<'a> { /* private fields */ }Expand description
Provides information about the GPU(s) on the system.
Implementations§
Source§impl<'a> GPUInfo<'a>
impl<'a> GPUInfo<'a>
Sourcepub fn builder(
devices: Vec<GPUDevice<'a>>,
driver_bug_workarounds: Vec<Cow<'a, str>>,
video_decoding: Vec<VideoDecodeAcceleratorCapability<'a>>,
video_encoding: Vec<VideoEncodeAcceleratorCapability<'a>>,
) -> GPUInfoBuilder<'a>
pub fn builder( devices: Vec<GPUDevice<'a>>, driver_bug_workarounds: Vec<Cow<'a, str>>, video_decoding: Vec<VideoDecodeAcceleratorCapability<'a>>, video_encoding: Vec<VideoEncodeAcceleratorCapability<'a>>, ) -> GPUInfoBuilder<'a>
Creates a builder for this type with the required parameters:
devices: The graphics devices on the system. Element 0 is the primary GPU.driver_bug_workarounds: An optional array of GPU driver bug workarounds.video_decoding: Supported accelerated video decoding capabilities.video_encoding: Supported accelerated video encoding capabilities.
Sourcepub fn devices(&self) -> &[GPUDevice<'a>]
pub fn devices(&self) -> &[GPUDevice<'a>]
The graphics devices on the system. Element 0 is the primary GPU.
Sourcepub fn aux_attributes(&self) -> Option<&Map<String, JsonValue>>
pub fn aux_attributes(&self) -> Option<&Map<String, JsonValue>>
An optional dictionary of additional GPU related attributes.
Sourcepub fn feature_status(&self) -> Option<&Map<String, JsonValue>>
pub fn feature_status(&self) -> Option<&Map<String, JsonValue>>
An optional dictionary of graphics features and their status.
Sourcepub fn driver_bug_workarounds(&self) -> &[Cow<'a, str>]
pub fn driver_bug_workarounds(&self) -> &[Cow<'a, str>]
An optional array of GPU driver bug workarounds.
Sourcepub fn video_decoding(&self) -> &[VideoDecodeAcceleratorCapability<'a>]
pub fn video_decoding(&self) -> &[VideoDecodeAcceleratorCapability<'a>]
Supported accelerated video decoding capabilities.
Sourcepub fn video_encoding(&self) -> &[VideoEncodeAcceleratorCapability<'a>]
pub fn video_encoding(&self) -> &[VideoEncodeAcceleratorCapability<'a>]
Supported accelerated video encoding capabilities.
Trait Implementations§
Source§impl<'de, 'a> Deserialize<'de> for GPUInfo<'a>
impl<'de, 'a> Deserialize<'de> for GPUInfo<'a>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl<'a> Freeze for GPUInfo<'a>
impl<'a> RefUnwindSafe for GPUInfo<'a>
impl<'a> Send for GPUInfo<'a>
impl<'a> Sync for GPUInfo<'a>
impl<'a> Unpin for GPUInfo<'a>
impl<'a> UnsafeUnpin for GPUInfo<'a>
impl<'a> UnwindSafe for GPUInfo<'a>
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