Struct wgpu_types::RequestAdapterOptions
source · #[repr(C)]pub struct RequestAdapterOptions<S> {
pub power_preference: PowerPreference,
pub force_fallback_adapter: bool,
pub compatible_surface: Option<S>,
}
Expand description
Options for requesting adapter.
Corresponds to WebGPU GPURequestAdapterOptions
.
Fields§
§power_preference: PowerPreference
Power preference for the adapter.
force_fallback_adapter: bool
Indicates that only a fallback adapter can be returned. This is generally a “software” implementation on the system.
compatible_surface: Option<S>
Surface that is required to be presentable with the requested adapter. This does not create the surface, only guarantees that the adapter can present to said surface.
Trait Implementations§
source§impl<S: Clone> Clone for RequestAdapterOptions<S>
impl<S: Clone> Clone for RequestAdapterOptions<S>
source§fn clone(&self) -> RequestAdapterOptions<S>
fn clone(&self) -> RequestAdapterOptions<S>
Returns a copy 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 moresource§impl<S: Debug> Debug for RequestAdapterOptions<S>
impl<S: Debug> Debug for RequestAdapterOptions<S>
source§impl<S> Default for RequestAdapterOptions<S>
impl<S> Default for RequestAdapterOptions<S>
source§impl<'de, S> Deserialize<'de> for RequestAdapterOptions<S>where
S: Deserialize<'de>,
impl<'de, S> Deserialize<'de> for RequestAdapterOptions<S>where S: Deserialize<'de>,
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
source§impl<S: Hash> Hash for RequestAdapterOptions<S>
impl<S: Hash> Hash for RequestAdapterOptions<S>
source§impl<S: PartialEq> PartialEq<RequestAdapterOptions<S>> for RequestAdapterOptions<S>
impl<S: PartialEq> PartialEq<RequestAdapterOptions<S>> for RequestAdapterOptions<S>
source§fn eq(&self, other: &RequestAdapterOptions<S>) -> bool
fn eq(&self, other: &RequestAdapterOptions<S>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.