#[non_exhaustive]pub enum OverlayError {
NoDevice,
Surface(String),
UnsupportedSurface,
NoTranslucentMode,
StraightAlpha,
Engine(EngineError),
}Expand description
Why an overlay could not be created or could not draw a frame.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NoDevice
The context has no device yet: an overlay shares the main surface’s device, so it is created after the main surface.
Surface(String)
The platform object could not be turned into a surface, or the surface could not be configured.
UnsupportedSurface
The main surface’s adapter cannot present to this surface. Refused rather than answered with a second device: the overlay must share the main frame’s device.
NoTranslucentMode
The platform granted no translucent composite mode — an opaque overlay would cover everything under it.
StraightAlpha
The compositor reads the overlay’s alpha straight, which the spike does not serve (no un-premultiplying pass).
Engine(EngineError)
The overlay’s engine renderer could not be built or refused the frame.
Trait Implementations§
Source§impl Debug for OverlayError
impl Debug for OverlayError
Source§impl Display for OverlayError
impl Display for OverlayError
Source§impl Error for OverlayError
impl Error for OverlayError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for OverlayError
impl RefUnwindSafe for OverlayError
impl Send for OverlayError
impl Sync for OverlayError
impl Unpin for OverlayError
impl UnsafeUnpin for OverlayError
impl UnwindSafe for OverlayError
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