pub fn resolve_alpha_mode(
request: SurfaceAlphaRequest,
capabilities: &SurfaceCapabilities,
) -> CompositeAlphaModeExpand description
Resolves a caller’s SurfaceAlphaRequest against the live surface’s
reported alpha_modes, choosing the actual wgpu::CompositeAlphaMode to
configure with.
Opaque resolves to Auto without consulting the surface at all.
TranslucentPreferred tries, in order, Inherit (Android’s only reported
translucent mode), PostMultiplied (iOS’s translucent mode), then
PreMultiplied — falling back to Auto with a log::warn! when none of the
three is in capabilities.alpha_modes (translucency is simply unavailable
on that surface).