Struct wgpu_hal::SurfaceCapabilities
source · [−]pub struct SurfaceCapabilities {
pub formats: Vec<TextureFormat>,
pub swap_chain_sizes: RangeInclusive<u32>,
pub current_extent: Option<Extent3d>,
pub extents: RangeInclusive<Extent3d>,
pub usage: TextureUses,
pub present_modes: Vec<PresentMode>,
pub composite_alpha_modes: Vec<CompositeAlphaMode>,
}Expand description
Describes information about what a Surface’s presentation capabilities are.
Fetch this with Adapter::surface_capabilities.
Fields
formats: Vec<TextureFormat>List of supported texture formats.
Must be at least one.
swap_chain_sizes: RangeInclusive<u32>Range for the swap chain sizes.
swap_chain_sizes.startmust be at least 1.swap_chain_sizes.endmust be larger or equal toswap_chain_sizes.start.
current_extent: Option<Extent3d>Current extent of the surface, if known.
extents: RangeInclusive<Extent3d>Range of supported extents.
current_extent must be inside this range.
usage: TextureUsesSupported texture usage flags.
Must have at least TextureUses::COLOR_TARGET
present_modes: Vec<PresentMode>List of supported V-sync modes.
Must be at least one.
composite_alpha_modes: Vec<CompositeAlphaMode>List of supported alpha composition modes.
Must be at least one.
Trait Implementations
sourceimpl Clone for SurfaceCapabilities
impl Clone for SurfaceCapabilities
sourcefn clone(&self) -> SurfaceCapabilities
fn clone(&self) -> SurfaceCapabilities
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
Auto Trait Implementations
impl RefUnwindSafe for SurfaceCapabilities
impl Send for SurfaceCapabilities
impl Sync for SurfaceCapabilities
impl Unpin for SurfaceCapabilities
impl UnwindSafe for SurfaceCapabilities
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more