gfx_hal/external_memory/
errors.rs1use crate::device::OutOfMemory;
4
5#[derive(Clone, Debug, PartialEq, thiserror::Error)]
6pub enum ExternalImagePropertiesError {
8 #[error(transparent)]
10 OutOfMemory(#[from] OutOfMemory),
11
12 #[error("Format not supported")]
14 FormatNotSupported,
15}
16
17#[derive(Clone, Debug, PartialEq, thiserror::Error)]
18pub enum ExternalResourceError {
20 #[error(transparent)]
22 OutOfMemory(#[from] OutOfMemory),
23
24 #[error("Too many objects")]
26 TooManyObjects,
27
28 #[error("No valid memory type id among the desired ones")]
30 NoValidMemoryTypeId,
31
32 #[error("The used external handle or the combination of them is invalid")]
34 InvalidExternalHandle,
35}
36
37#[derive(Clone, Debug, PartialEq, thiserror::Error)]
38pub enum ExternalMemoryExportError {
40 #[error("Too many objects")]
42 TooManyObjects,
43
44 #[error("Out of host memory")]
46 OutOfHostMemory,
47
48 #[error("Invalid external handle")]
50 InvalidExternalHandle,
51}