pub enum VmbError {
Sdk {
code: i32,
message: String,
},
NotStarted,
AlreadyStarted,
Io {
path: PathBuf,
source: Error,
},
InvalidString {
context: &'static str,
},
CaptureAlreadyRunning,
FrameTooSmall {
expected: usize,
actual: usize,
},
LoadFailed {
message: String,
},
}Expand description
Errors returned by the safe vmb wrapper.
Variants§
Sdk
A non-success return code from a VmbC call.
Fields
NotStarted
The Vimba runtime has not been started, or was already shut down.
AlreadyStarted
Attempted to start the Vimba runtime while a previous VmbSystem
instance is still alive. The runtime is process-global and the
wrapper enforces a singleton invariant.
Io
I/O failure while reading a settings XML file (or a related path).
InvalidString
A string supplied by the SDK or by the caller was not valid UTF-8 or contained an interior nul byte.
CaptureAlreadyRunning
Camera::start_capture was called while a previous capture is still
running on the same camera.
FrameTooSmall
A received frame was smaller than expected for its declared format.
Fields
LoadFailed
Failed to load the Vimba X shared library at runtime, or resolve
one of its symbols. Typically surfaced from VmbFfiRuntime::new
when the SDK is not installed on the host.
Trait Implementations§
Source§impl Error for VmbError
impl Error for VmbError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()