pub enum MovieError {
BadMagic,
UnsupportedVersion {
found: u16,
max: u16,
},
BadStartPointKind(u8),
RomMismatch,
SeedMismatch {
expected: u64,
found: u64,
},
SaveState(SaveStateError),
Truncated,
}Expand description
Errors from decoding or replaying a movie.
Variants§
BadMagic
The blob’s leading magic bytes didn’t match — not a RustySNES movie at all.
UnsupportedVersion
The format version is newer than this build understands.
BadStartPointKind(u8)
The start-point kind byte was neither 0 (power-on) nor 1 (save-state).
RomMismatch
Movie::verify_rom was called with bytes that don’t hash to this movie’s recorded
rom_sha256 — replaying against the wrong ROM would not reproduce the recording.
SeedMismatch
Movie::seek_to_start was called for a StartPoint::PowerOn movie against a
System whose seed doesn’t match the movie’s recorded seed — replay would diverge from
the very first frame (different power-on phase alignment), not just eventually.
Fields
SaveState(SaveStateError)
The embedded save-state failed to decode/restore.
Truncated
The buffer ended before the expected number of bytes were available.
Trait Implementations§
Source§impl Debug for MovieError
impl Debug for MovieError
Source§impl Display for MovieError
impl Display for MovieError
Source§impl Error for MovieError
impl Error for MovieError
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()
Source§impl From<SaveStateError> for MovieError
impl From<SaveStateError> for MovieError
Source§fn from(source: SaveStateError) -> Self
fn from(source: SaveStateError) -> Self
Source§impl PartialEq for MovieError
impl PartialEq for MovieError
impl Eq for MovieError
impl StructuralPartialEq for MovieError
Auto Trait Implementations§
impl Freeze for MovieError
impl RefUnwindSafe for MovieError
impl Send for MovieError
impl Sync for MovieError
impl Unpin for MovieError
impl UnsafeUnpin for MovieError
impl UnwindSafe for MovieError
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
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.