#[non_exhaustive]pub enum GpuError {
Disabled,
NoLoader,
NoAdapter,
Unsupported(&'static str),
Invalid(&'static str),
OutOfMemory,
DeviceLost,
SurfaceLost,
Timeout,
NotReady,
Failed(i32),
}Expand description
what went wrong
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.
Disabled
the GPU is switched off (jfgui_GPU=0)
NoLoader
the GPU API is not installed (no vulkan-1.dll or libvulkan.so.1, jfgui_GPU_DLL names a missing file, a Linux program not linked against glibc, a browser without navigator.gpu)
NoAdapter
no usable GPU (or jfgui_GPU_ADAPTER matched none)
Unsupported(&'static str)
the adapter or this backend lacks something (a feature, a format, the level)
Invalid(&'static str)
a call the API does not allow (sizes, alignments, states, order)
OutOfMemory
host or device memory exhausted
DeviceLost
the device was lost (driver reset, GPU removed): recreate it
SurfaceLost
the window’s surface is gone
Timeout
a wait ran out of time
NotReady
results are not available yet (timestamps not written or not finished)
Failed(i32)
another failure of the GPU API (its code: a VkResult)
Trait Implementations§
impl Copy for GpuError
impl Eq for GpuError
impl StructuralPartialEq for GpuError
Auto Trait Implementations§
impl Forget for GpuError
impl Freeze for GpuError
impl RefUnwindSafe for GpuError
impl Send for GpuError
impl Sync for GpuError
impl Unpin for GpuError
impl UnsafeUnpin for GpuError
impl UnwindSafe for GpuError
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