pub enum RenderError {
Reconfigure,
Skip,
Validation,
DeviceLost,
}Expand description
A frame that produced no image, and what to do about it.
Mapped from wgpu’s CurrentSurfaceTexture; the crate root’s example
handles every variant.
Variants§
Reconfigure
The surface is outdated or lost: call Renderer::resize with the
window’s size and draw again.
Skip
Nothing can be presented right now (the window is occluded, or the acquire timed out): try again next frame.
Validation
The surface is configured wrong for the window: call
Renderer::resize with the window’s size and draw again. A
surface that stays wrong is best given up with its device.
DeviceLost
The device is gone (Gpu::lost): open a new one, and a renderer
on it for every window.
Trait Implementations§
Source§impl Clone for RenderError
impl Clone for RenderError
impl Copy for RenderError
Source§impl Debug for RenderError
impl Debug for RenderError
Source§impl Display for RenderError
impl Display for RenderError
Source§impl Error for RenderError
impl Error for RenderError
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 RenderError
impl RefUnwindSafe for RenderError
impl Send for RenderError
impl Sync for RenderError
impl Unpin for RenderError
impl UnsafeUnpin for RenderError
impl UnwindSafe for RenderError
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